:root {
  --deep-950: #000f17;
  --deep-900: #00141a;
  --deep-850: #001d2b;
  --deep-800: #002840;
  --deep-700: #004166;
  --ocean-500: #0099e6;
  --ocean-400: #1ab1ff;
  --ocean-300: #4dc2ff;
  --teal-500: #14b8a6;
  --text: #ffffff;
  --muted: #b6e6ff;
  --soft: #7cccf3;
  --line: rgba(77, 194, 255, 0.18);
  --shadow: 0 4px 20px rgba(0, 153, 230, 0.15);
  --shadow-lg: 0 10px 40px rgba(0, 153, 230, 0.22);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: linear-gradient(180deg, var(--deep-950), var(--deep-900) 42%, var(--deep-950));
  color: var(--text);
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", Arial, sans-serif;
  line-height: 1.6;
}

body.menu-open {
  overflow: hidden;
}

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

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

button,
input {
  font: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: linear-gradient(90deg, rgba(0, 20, 26, 0.96), rgba(0, 40, 64, 0.96), rgba(0, 26, 38, 0.96));
  box-shadow: var(--shadow);
  backdrop-filter: blur(10px);
}

.nav-wrap {
  max-width: 1220px;
  margin: 0 auto;
  padding: 14px 20px;
  display: flex;
  align-items: center;
  gap: 22px;
}

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

.brand-icon {
  width: 44px;
  height: 44px;
  border-radius: 16px;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, var(--ocean-400), var(--teal-500));
  color: #ffffff;
  box-shadow: var(--shadow);
  transition: transform 0.25s ease;
}

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

.brand-text strong {
  display: block;
  font-size: 22px;
  letter-spacing: 0.04em;
}

.brand-text small {
  display: block;
  color: var(--muted);
  font-size: 12px;
  margin-top: -2px;
}

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

.nav-link {
  color: #d7f2ff;
  font-weight: 650;
  transition: color 0.2s ease;
}

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

.header-search {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px;
  border: 1px solid var(--line);
  background: rgba(0, 26, 38, 0.64);
  border-radius: 14px;
}

.header-search input,
.mobile-search input,
.quick-search input,
.filter-panel input {
  color: #ffffff;
  background: rgba(0, 15, 23, 0.72);
  border: 1px solid rgba(77, 194, 255, 0.24);
  border-radius: 12px;
  outline: none;
}

.header-search input {
  width: 160px;
  padding: 9px 12px;
}

.header-search button,
.mobile-search button,
.quick-search button {
  border: 0;
  cursor: pointer;
  color: #ffffff;
  background: linear-gradient(90deg, var(--ocean-500), var(--teal-500));
  border-radius: 12px;
  padding: 9px 14px;
  font-weight: 700;
}

.menu-toggle {
  display: none;
  margin-left: auto;
  background: rgba(0, 85, 128, 0.5);
  color: #ffffff;
  border: 0;
  border-radius: 12px;
  width: 42px;
  height: 42px;
  cursor: pointer;
}

.mobile-panel {
  display: none;
  padding: 0 20px 18px;
  border-top: 1px solid var(--line);
  background: rgba(0, 20, 26, 0.98);
}

.mobile-link {
  display: block;
  padding: 12px 0;
  color: var(--muted);
  border-bottom: 1px solid rgba(77, 194, 255, 0.1);
}

.mobile-link.active,
.mobile-link:hover {
  color: #ffffff;
}

.mobile-search {
  display: flex;
  gap: 8px;
  margin-top: 14px;
}

.mobile-search input {
  flex: 1;
  padding: 11px 12px;
}

main {
  min-height: 70vh;
}

.hero-carousel {
  position: relative;
  min-height: 70vh;
  overflow: hidden;
  background: var(--deep-950);
}

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

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

.hero-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(1.08);
}

.hero-shade {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(0, 15, 23, 0.96), rgba(0, 40, 64, 0.78), rgba(0, 20, 26, 0.15)),
    linear-gradient(0deg, var(--deep-950), transparent 45%);
}

.hero-content {
  position: relative;
  z-index: 2;
  min-height: 70vh;
  max-width: 1220px;
  margin: 0 auto;
  padding: 74px 20px 70px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 280px;
  align-items: center;
  gap: 58px;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  width: max-content;
  max-width: 100%;
  color: var(--ocean-300);
  background: rgba(0, 153, 230, 0.15);
  border: 1px solid rgba(77, 194, 255, 0.26);
  border-radius: 999px;
  padding: 7px 13px;
  font-weight: 700;
  font-size: 14px;
}

.hero-copy h1 {
  margin: 18px 0 14px;
  font-size: clamp(38px, 7vw, 72px);
  line-height: 1.05;
  letter-spacing: -0.04em;
}

.hero-copy p {
  max-width: 700px;
  color: #d4f3ff;
  font-size: 18px;
  margin: 0 0 24px;
}

.hero-tags,
.detail-meta,
.filter-chips,
.quick-links,
.card-tags,
.detail-tags {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}

.hero-tags span,
.detail-meta span,
.tag,
.filter-chips a,
.quick-links a {
  color: var(--ocean-300);
  background: rgba(0, 153, 230, 0.14);
  border: 1px solid rgba(77, 194, 255, 0.22);
  border-radius: 999px;
  padding: 7px 12px;
  font-size: 13px;
}

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

.primary-btn,
.ghost-btn,
.text-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 14px;
  font-weight: 800;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.primary-btn {
  color: #ffffff;
  padding: 13px 26px;
  background: linear-gradient(90deg, var(--ocean-500), var(--teal-500));
  box-shadow: var(--shadow);
}

.primary-btn:hover,
.ghost-btn:hover,
.text-link:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

.ghost-btn {
  color: #ffffff;
  padding: 12px 24px;
  border: 1px solid rgba(77, 194, 255, 0.3);
  background: rgba(0, 40, 64, 0.54);
}

.hero-poster {
  display: block;
  border-radius: 26px;
  overflow: hidden;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.38), var(--shadow-lg);
  aspect-ratio: 2 / 3;
  transform: rotate(2deg);
  border: 1px solid rgba(77, 194, 255, 0.22);
}

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

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

.hero-dot {
  width: 18px;
  height: 6px;
  border: 0;
  border-radius: 999px;
  background: rgba(77, 194, 255, 0.42);
  cursor: pointer;
  transition: width 0.25s ease, background 0.25s ease;
}

.hero-dot.active {
  width: 42px;
  background: var(--ocean-400);
}

.quick-search {
  max-width: 1040px;
  margin: -42px auto 0;
  position: relative;
  z-index: 10;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: rgba(0, 40, 64, 0.78);
  box-shadow: var(--shadow-lg);
  backdrop-filter: blur(14px);
}

.quick-search form {
  display: grid;
  grid-template-columns: 1fr 140px;
  gap: 12px;
}

.quick-search input {
  padding: 14px 16px;
}

.quick-links {
  margin-top: 14px;
}

.content-section {
  max-width: 1220px;
  margin: 0 auto;
  padding: 72px 20px;
}

.band-section {
  background: linear-gradient(180deg, rgba(0, 20, 26, 0.1), rgba(0, 40, 64, 0.48), rgba(0, 20, 26, 0.1));
}

.section-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 28px;
}

.section-heading h2 {
  margin: 0;
  font-size: clamp(26px, 4vw, 36px);
}

.section-heading p {
  margin: 4px 0 0;
  color: var(--soft);
}

.section-icon {
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border-radius: 16px;
  background: rgba(0, 153, 230, 0.16);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
}

.horizontal-cards {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: 250px;
  gap: 18px;
  overflow-x: auto;
  padding: 4px 2px 18px;
  scroll-snap-type: x mandatory;
}

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

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

.movie-card {
  border-radius: 22px;
  background: rgba(0, 40, 64, 0.72);
  border: 1px solid rgba(77, 194, 255, 0.14);
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.movie-card:hover {
  transform: translateY(-4px);
  border-color: rgba(77, 194, 255, 0.34);
  box-shadow: var(--shadow-lg);
}

.poster {
  position: relative;
  display: block;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  background: var(--deep-800);
}

.poster img,
.ranking-cover img,
.detail-poster img,
.category-card-posters img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.45s ease;
}

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

.poster-gradient {
  position: absolute;
  inset: auto 0 0 0;
  height: 50%;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.82), transparent);
}

.type-badge,
.rank-badge {
  position: absolute;
  top: 12px;
  z-index: 2;
  border-radius: 999px;
  color: #ffffff;
  font-size: 12px;
  font-weight: 800;
  padding: 5px 9px;
  background: rgba(0, 0, 0, 0.62);
  backdrop-filter: blur(6px);
}

.type-badge {
  right: 12px;
}

.rank-badge {
  left: 12px;
  background: linear-gradient(135deg, var(--ocean-500), var(--teal-500));
}

.card-body {
  padding: 16px;
}

.movie-card-small .card-body {
  padding: 12px;
}

.card-body h3 {
  margin: 0 0 6px;
  color: #ffffff;
  font-size: 17px;
  line-height: 1.35;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.movie-card-small .card-body h3 {
  font-size: 14px;
}

.card-meta,
.card-desc {
  margin: 0;
  color: var(--soft);
  font-size: 13px;
}

.card-desc {
  min-height: 42px;
  margin-top: 8px;
  color: #c5edff;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.movie-card-small .card-desc {
  display: none;
}

.card-tags {
  margin-top: 12px;
}

.card-tags .tag {
  padding: 4px 8px;
  font-size: 12px;
}

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

.category-feature,
.category-card,
.detail-card,
.filter-panel {
  border: 1px solid rgba(77, 194, 255, 0.16);
  border-radius: 26px;
  background: rgba(0, 40, 64, 0.7);
  box-shadow: var(--shadow);
}

.category-feature {
  padding: 22px;
}

.category-feature-head,
.category-card {
  display: flex;
  justify-content: space-between;
  gap: 18px;
}

.category-feature-head {
  align-items: flex-start;
  margin-bottom: 18px;
}

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

.category-feature-head p,
.category-card p {
  margin: 0;
  color: var(--soft);
}

.category-feature-head a,
.text-link {
  color: var(--ocean-300);
}

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

.page-hero {
  max-width: 1220px;
  margin: 0 auto;
  padding: 86px 20px 32px;
}

.small-hero > div {
  padding: 42px;
  border-radius: 30px;
  border: 1px solid rgba(77, 194, 255, 0.18);
  background:
    radial-gradient(circle at 15% 15%, rgba(26, 177, 255, 0.22), transparent 30%),
    linear-gradient(135deg, rgba(0, 40, 64, 0.88), rgba(0, 20, 26, 0.92));
  box-shadow: var(--shadow-lg);
}

.small-hero h1 {
  margin: 18px 0 10px;
  font-size: clamp(32px, 5vw, 52px);
  line-height: 1.12;
}

.small-hero p {
  max-width: 780px;
  color: #ccefff;
  font-size: 17px;
  margin: 0;
}

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

.category-card {
  padding: 24px;
  align-items: center;
  overflow: hidden;
}

.category-card-copy span {
  color: var(--ocean-300);
  font-weight: 800;
  font-size: 13px;
}

.category-card-posters {
  width: 180px;
  min-width: 180px;
  height: 130px;
  display: flex;
  align-items: center;
  justify-content: flex-end;
}

.category-card-posters img {
  width: 72px;
  height: 108px;
  border-radius: 14px;
  margin-left: -28px;
  border: 2px solid rgba(255, 255, 255, 0.16);
  box-shadow: 0 12px 24px rgba(0, 0, 0, 0.28);
}

.filter-panel {
  padding: 20px;
  margin-bottom: 26px;
}

.filter-panel input {
  width: 100%;
  padding: 14px 16px;
  margin-bottom: 14px;
}

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

.ranking-item {
  display: grid;
  grid-template-columns: 86px 54px minmax(0, 1fr) 90px;
  gap: 18px;
  align-items: center;
  padding: 14px;
}

.ranking-cover {
  display: block;
  width: 86px;
  height: 126px;
  border-radius: 14px;
  overflow: hidden;
  background: var(--deep-800);
}

.ranking-number {
  color: #ffffff;
  font-size: 28px;
  font-weight: 900;
  text-align: center;
}

.ranking-content h2 {
  margin: 0 0 5px;
  font-size: 22px;
}

.ranking-content p {
  margin: 0;
  color: #d2f2ff;
}

.ranking-meta {
  color: var(--soft) !important;
  font-size: 13px;
  margin-bottom: 8px !important;
}

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

.detail-layout {
  max-width: 1220px;
  margin: 0 auto;
  padding: 38px 20px 0;
}

.breadcrumb {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  color: var(--soft);
  margin-bottom: 18px;
}

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

.player-shell {
  position: relative;
  border-radius: 28px;
  overflow: hidden;
  background: #000000;
  box-shadow: var(--shadow-lg);
  border: 1px solid rgba(77, 194, 255, 0.16);
}

.movie-player {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #000000;
  cursor: pointer;
}

.player-start {
  position: absolute;
  inset: 0;
  margin: auto;
  width: 96px;
  height: 96px;
  border-radius: 50%;
  border: 0;
  background: linear-gradient(135deg, var(--ocean-500), var(--teal-500));
  color: #ffffff;
  font-size: 42px;
  cursor: pointer;
  box-shadow: 0 16px 50px rgba(0, 153, 230, 0.36);
  transition: transform 0.22s ease, opacity 0.22s ease;
  z-index: 5;
}

.player-start span {
  display: inline-block;
  margin-left: 6px;
}

.player-start:hover {
  transform: scale(1.08);
}

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

.detail-card {
  margin-top: 26px;
  padding: 28px;
  display: grid;
  grid-template-columns: 240px minmax(0, 1fr);
  gap: 30px;
}

.detail-poster {
  border-radius: 24px;
  overflow: hidden;
  aspect-ratio: 2 / 3;
  background: var(--deep-800);
  box-shadow: var(--shadow);
}

.detail-copy h1 {
  margin: 0 0 16px;
  font-size: clamp(30px, 5vw, 46px);
  line-height: 1.16;
}

.detail-tags {
  margin: 18px 0 24px;
}

.detail-copy h2 {
  margin: 22px 0 10px;
  font-size: 22px;
}

.detail-copy p {
  color: #d3f2ff;
  margin: 0 0 12px;
}

.lead-text {
  color: #ffffff !important;
  font-weight: 700;
}

.site-footer {
  border-top: 1px solid var(--line);
  background: rgba(0, 15, 23, 0.82);
  margin-top: 40px;
}

.footer-inner {
  max-width: 1220px;
  margin: 0 auto;
  padding: 34px 20px;
  display: flex;
  justify-content: space-between;
  gap: 24px;
}

.footer-inner p {
  color: var(--soft);
  margin: 6px 0 0;
}

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

.footer-links a {
  color: var(--muted);
}

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

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

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

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

  body.menu-open .mobile-panel {
    display: block;
  }

  .hero-content {
    grid-template-columns: 1fr;
    gap: 28px;
  }

  .hero-poster {
    display: none;
  }

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

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

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

  .detail-card {
    grid-template-columns: 180px minmax(0, 1fr);
  }
}

@media (max-width: 760px) {
  .nav-wrap {
    padding: 12px 16px;
  }

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

  .brand-text small {
    display: none;
  }

  .hero-carousel,
  .hero-content {
    min-height: 640px;
  }

  .hero-content {
    padding: 58px 16px 72px;
  }

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

  .quick-search {
    margin: -32px 16px 0;
    padding: 16px;
  }

  .quick-search form {
    grid-template-columns: 1fr;
  }

  .content-section {
    padding: 48px 16px;
  }

  .section-heading {
    align-items: flex-start;
    justify-content: flex-start;
  }

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

  .horizontal-cards {
    grid-auto-columns: 210px;
  }

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

  .page-hero {
    padding: 54px 16px 20px;
  }

  .small-hero > div {
    padding: 28px;
  }

  .category-card {
    display: block;
  }

  .category-card-posters {
    width: 100%;
    justify-content: flex-start;
    margin-top: 18px;
  }

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

  .ranking-number,
  .ranking-score {
    display: none;
  }

  .ranking-cover {
    width: 72px;
    height: 108px;
  }

  .ranking-content h2 {
    font-size: 18px;
  }

  .detail-layout {
    padding: 26px 16px 0;
  }

  .detail-card {
    grid-template-columns: 1fr;
    padding: 18px;
  }

  .detail-poster {
    max-width: 220px;
  }

  .player-start {
    width: 76px;
    height: 76px;
    font-size: 34px;
  }

  .footer-inner {
    display: block;
    padding: 28px 16px;
  }

  .footer-links {
    margin-top: 18px;
  }
}

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

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