:root {
  --page-bg: #f8fafc;
  --text: #111827;
  --muted: #64748b;
  --soft: #e5e7eb;
  --card: #ffffff;
  --blue: #2563eb;
  --blue-dark: #1e3a8a;
  --cyan: #06b6d4;
  --amber: #f59e0b;
  --shadow-sm: 0 4px 14px rgba(15, 23, 42, 0.08);
  --shadow-md: 0 14px 34px rgba(15, 23, 42, 0.12);
  --shadow-lg: 0 26px 60px rgba(15, 23, 42, 0.18);
  --radius-lg: 24px;
  --radius-md: 18px;
  --radius-sm: 12px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: linear-gradient(135deg, #f9fafb 0%, #eff6ff 100%);
  color: var(--text);
  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;
}

button {
  cursor: pointer;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid rgba(226, 232, 240, 0.84);
}

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

.logo,
.footer-logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  white-space: nowrap;
}

.logo-mark {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  color: #ffffff;
  background: linear-gradient(135deg, var(--blue), var(--cyan));
  border-radius: 999px;
  box-shadow: 0 10px 24px rgba(37, 99, 235, 0.28);
}

.logo-text {
  font-size: 20px;
}

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 6px;
  flex: 1;
  min-width: 0;
}

.nav-link,
.mobile-link {
  color: #334155;
  font-weight: 650;
  padding: 10px 12px;
  border-radius: 999px;
  transition: color 0.2s ease, background 0.2s ease;
}

.nav-link:hover,
.nav-link.active,
.mobile-link:hover,
.mobile-link.active {
  color: var(--blue);
  background: #eff6ff;
}

.site-search-form {
  display: flex;
  align-items: center;
  gap: 8px;
}

.site-search-input,
.page-filter-input,
.catalog-tools select {
  border: 1px solid #cbd5e1;
  border-radius: 999px;
  padding: 10px 14px;
  background: #ffffff;
  color: #0f172a;
  outline: none;
  min-width: 210px;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.site-search-input:focus,
.page-filter-input:focus,
.catalog-tools select:focus {
  border-color: var(--blue);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.16);
}

.site-search-button,
.primary-action,
.section-more,
.ranking-action {
  border: 0;
  border-radius: 999px;
  background: var(--blue);
  color: #ffffff;
  font-weight: 750;
  padding: 10px 18px;
  box-shadow: var(--shadow-sm);
  transition: transform 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
}

.site-search-button:hover,
.primary-action:hover,
.section-more:hover,
.ranking-action:hover {
  background: #1d4ed8;
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}

.menu-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 12px;
  background: #eff6ff;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
}

.menu-toggle span {
  width: 20px;
  height: 2px;
  background: #1e3a8a;
  border-radius: 999px;
}

.mobile-nav {
  width: min(1280px, calc(100% - 32px));
  margin: 0 auto;
  padding: 0 0 18px;
  display: grid;
  gap: 8px;
}

.mobile-search {
  align-items: stretch;
}

.search-panel {
  position: fixed;
  inset: 0;
  z-index: 80;
  background: rgba(15, 23, 42, 0.45);
  padding: 96px 16px 24px;
}

.search-panel-card {
  width: min(760px, 100%);
  max-height: calc(100vh - 132px);
  margin: 0 auto;
  overflow: auto;
  background: #ffffff;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  padding: 24px;
  position: relative;
}

.search-panel-card h2 {
  margin: 0 0 18px;
  font-size: 26px;
}

.search-close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 36px;
  height: 36px;
  border: 0;
  border-radius: 999px;
  background: #f1f5f9;
  color: #0f172a;
  font-size: 24px;
}

.search-result-item {
  display: grid;
  gap: 4px;
  padding: 14px 0;
  border-bottom: 1px solid #e2e8f0;
}

.search-result-item strong {
  color: var(--blue);
}

.search-result-item span {
  color: var(--muted);
  font-size: 14px;
}

.hero-carousel {
  position: relative;
  height: 600px;
  overflow: hidden;
  background: linear-gradient(90deg, #1e3a8a 0%, #1e40af 48%, #164e63 100%);
}

.hero-slides,
.hero-slide {
  position: absolute;
  inset: 0;
}

.hero-slide {
  opacity: 0;
  pointer-events: none;
  transition: opacity 1s ease;
}

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

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

.hero-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(0, 0, 0, 0.84) 0%, rgba(0, 0, 0, 0.52) 50%, rgba(0, 0, 0, 0.08) 100%);
}

.hero-content {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
}

.hero-copy {
  width: min(1280px, calc(100% - 32px));
  margin: 0 auto;
  color: #ffffff;
}

.hero-copy h1,
.hero-copy h2 {
  width: min(720px, 100%);
  margin: 0 0 22px;
  font-size: clamp(40px, 6vw, 72px);
  line-height: 1.04;
  font-weight: 900;
  letter-spacing: -0.04em;
}

.hero-copy p {
  width: min(680px, 100%);
  margin: 0 0 26px;
  color: #e5e7eb;
  font-size: clamp(17px, 2vw, 22px);
}

.hero-pill,
.eyebrow,
.detail-label {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  border-radius: 999px;
  background: var(--blue);
  color: #ffffff;
  font-size: 14px;
  font-weight: 800;
  padding: 8px 14px;
  margin-bottom: 16px;
}

.eyebrow {
  background: #dbeafe;
  color: #1d4ed8;
}

.eyebrow.light {
  background: rgba(255, 255, 255, 0.18);
  color: #ffffff;
}

.hero-meta,
.movie-meta,
.detail-meta-grid {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}

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

.hero-meta span {
  padding: 6px 12px;
  background: rgba(255, 255, 255, 0.18);
  backdrop-filter: blur(8px);
  border-radius: 999px;
  color: #ffffff;
}

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

.ghost-action {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 10px 18px;
  color: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.42);
  background: rgba(255, 255, 255, 0.12);
  transition: background 0.2s ease, transform 0.2s ease;
}

.ghost-action:hover {
  background: rgba(255, 255, 255, 0.22);
  transform: translateY(-1px);
}

.hero-arrow {
  position: absolute;
  top: 50%;
  width: 52px;
  height: 52px;
  transform: translateY(-50%);
  border: 0;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.13);
  backdrop-filter: blur(10px);
  font-size: 42px;
  line-height: 1;
  transition: background 0.2s ease, transform 0.2s ease;
}

.hero-arrow:hover {
  background: rgba(255, 255, 255, 0.24);
  transform: translateY(-50%) scale(1.05);
}

.hero-prev {
  left: 24px;
}

.hero-next {
  right: 24px;
}

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

.hero-dot {
  width: 12px;
  height: 12px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.52);
  transition: width 0.25s ease, background 0.25s ease;
}

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

.section {
  padding: 64px 0;
}

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

.section-head.centered {
  display: grid;
  justify-items: center;
  text-align: center;
}

.section-head h2,
.page-hero h1,
.detail-panel h1,
.detail-copy h2,
.hot-band h2 {
  margin: 0;
  color: #0f172a;
  font-size: clamp(28px, 4vw, 44px);
  line-height: 1.12;
  font-weight: 900;
  letter-spacing: -0.03em;
}

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

.category-grid,
.movie-grid,
.category-overview-grid {
  display: grid;
  gap: 22px;
}

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

.category-tile {
  min-height: 160px;
  display: grid;
  gap: 8px;
  align-content: center;
  justify-items: center;
  text-align: center;
  background: #ffffff;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  padding: 24px;
  transition: transform 0.24s ease, box-shadow 0.24s ease;
}

.category-tile:hover,
.movie-card:hover,
.category-overview-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.category-tile span,
.category-overview-main span {
  width: 52px;
  height: 52px;
  display: grid;
  place-items: center;
  color: #ffffff;
  background: linear-gradient(135deg, var(--blue), var(--cyan));
  border-radius: 999px;
  font-size: 22px;
  font-weight: 900;
}

.category-tile strong {
  font-size: 18px;
}

.category-tile em {
  color: var(--muted);
  font-style: normal;
  font-size: 13px;
}

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

.movie-card {
  overflow: hidden;
  border-radius: var(--radius-md);
  background: #ffffff;
  box-shadow: var(--shadow-sm);
  transition: transform 0.24s ease, box-shadow 0.24s ease;
}

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

.poster-frame {
  position: relative;
  height: 250px;
  overflow: hidden;
  background: linear-gradient(135deg, #1e3a8a, #0891b2);
}

.movie-card-large .poster-frame {
  height: 360px;
}

.poster-frame img,
.compact-thumb img,
.ranking-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.movie-card:hover .poster-frame img,
.compact-card:hover .compact-thumb img,
.ranking-card:hover .ranking-thumb img {
  transform: scale(1.08);
}

.poster-frame::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.62) 0%, rgba(0, 0, 0, 0) 62%);
}

.poster-badge {
  position: absolute;
  top: 14px;
  right: 14px;
  z-index: 2;
  padding: 6px 10px;
  border-radius: 999px;
  background: var(--blue);
  color: #ffffff;
  font-size: 12px;
  font-weight: 800;
}

.movie-card-body {
  padding: 18px;
}

.movie-card h3 {
  margin: 0 0 8px;
  font-size: 19px;
  line-height: 1.3;
  font-weight: 850;
  transition: color 0.2s ease;
}

.movie-card:hover h3 {
  color: var(--blue);
}

.movie-card p {
  min-height: 48px;
  margin: 0 0 14px;
  color: #475569;
  font-size: 14px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.movie-meta {
  color: #64748b;
  font-size: 12px;
}

.movie-meta span {
  border-radius: 999px;
  background: #f1f5f9;
  padding: 4px 8px;
}

.tag-row,
.detail-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 14px;
}

.tag-row span,
.detail-tags span {
  padding: 5px 9px;
  border-radius: 999px;
  background: #f8fafc;
  color: #64748b;
  font-size: 12px;
}

.hot-band {
  overflow: hidden;
  border-radius: 32px;
  padding: 42px;
  color: #ffffff;
  background: linear-gradient(135deg, #2563eb, #06b6d4);
  box-shadow: 0 24px 60px rgba(37, 99, 235, 0.28);
}

.hot-band h2,
.hot-band .compact-card h3 {
  color: #ffffff;
}

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

.hot-band-head a {
  border-radius: 999px;
  padding: 10px 16px;
  background: rgba(255, 255, 255, 0.16);
}

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

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

.compact-card {
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.12);
  overflow: hidden;
  transition: background 0.2s ease, transform 0.2s ease;
}

.recommendation-panel .compact-card {
  background: #ffffff;
  box-shadow: var(--shadow-sm);
}

.compact-card:hover {
  background: rgba(255, 255, 255, 0.2);
  transform: translateY(-2px);
}

.compact-card a {
  display: flex;
  gap: 14px;
  align-items: center;
  padding: 14px;
}

.compact-thumb {
  width: 92px;
  height: 92px;
  flex: 0 0 auto;
  overflow: hidden;
  border-radius: 12px;
  background: linear-gradient(135deg, #1e3a8a, #0891b2);
}

.compact-card h3 {
  margin: 0 0 6px;
  color: #0f172a;
  font-size: 17px;
  line-height: 1.35;
}

.compact-card p {
  margin: 0;
  color: #94a3b8;
  font-size: 13px;
}

.page-shell {
  min-height: 70vh;
}

.page-hero {
  margin-top: 36px;
  padding: 54px;
  border-radius: 32px;
  background: linear-gradient(135deg, #ffffff, #eff6ff);
  box-shadow: var(--shadow-sm);
}

.small-hero h1,
.ranking-hero h1 {
  max-width: 900px;
}

.catalog-tools {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 28px;
  padding: 18px;
  border-radius: var(--radius-md);
  background: #ffffff;
  box-shadow: var(--shadow-sm);
}

.catalog-tools .page-filter-input {
  flex: 1 1 280px;
}

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

.category-overview-card {
  display: grid;
  gap: 18px;
  border-radius: var(--radius-lg);
  background: #ffffff;
  padding: 28px;
  box-shadow: var(--shadow-sm);
  transition: transform 0.24s ease, box-shadow 0.24s ease;
}

.category-overview-main {
  display: grid;
  gap: 12px;
}

.category-overview-main h2 {
  margin: 0;
  font-size: 28px;
}

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

.category-samples {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.category-samples a {
  padding: 7px 10px;
  border-radius: 999px;
  background: #f1f5f9;
  color: #334155;
  font-size: 13px;
}

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

.ranking-card {
  border-radius: var(--radius-md);
}

.ranking-card a {
  display: grid;
  grid-template-columns: 56px 110px 1fr auto;
  align-items: center;
  gap: 18px;
  padding: 14px 18px;
}

.ranking-number {
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--blue), var(--cyan));
  font-weight: 900;
}

.ranking-thumb {
  width: 110px;
  height: 76px;
  border-radius: 12px;
  overflow: hidden;
  background: linear-gradient(135deg, #1e3a8a, #0891b2);
}

.ranking-body h2 {
  margin: 0 0 6px;
  font-size: 20px;
}

.ranking-body p {
  margin: 0 0 10px;
  color: var(--muted);
  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.detail-main {
  background: #f8fafc;
}

.detail-hero {
  background: linear-gradient(135deg, #111827 0%, #1e3a8a 58%, #164e63 100%);
  color: #ffffff;
  padding: 34px 0 60px;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  margin-bottom: 24px;
  color: #cbd5e1;
}

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

.watch-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.7fr) minmax(320px, 0.8fr);
  gap: 28px;
  align-items: stretch;
}

.movie-player {
  position: relative;
  overflow: hidden;
  min-height: 360px;
  aspect-ratio: 16 / 9;
  border-radius: 24px;
  background: #000000;
  box-shadow: var(--shadow-lg);
}

.movie-player video {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #000000;
}

.play-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 14px;
  border: 0;
  color: #ffffff;
  background: radial-gradient(circle, rgba(37, 99, 235, 0.18) 0%, rgba(0, 0, 0, 0.58) 72%);
  transition: opacity 0.25s ease, visibility 0.25s ease;
}

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

.play-circle {
  width: 76px;
  height: 76px;
  display: grid;
  place-items: center;
  padding-left: 5px;
  border-radius: 999px;
  background: var(--blue);
  box-shadow: 0 16px 42px rgba(37, 99, 235, 0.36);
  font-size: 34px;
}

.detail-panel {
  display: grid;
  align-content: center;
  border-radius: 24px;
  padding: 28px;
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(10px);
  box-shadow: var(--shadow-md);
}

.detail-panel h1 {
  color: #ffffff;
  margin-bottom: 14px;
}

.detail-one-line {
  margin: 0 0 20px;
  color: #dbeafe;
}

.detail-meta-grid {
  gap: 10px;
  margin-bottom: 14px;
}

.detail-meta-grid span,
.detail-tags span {
  background: rgba(255, 255, 255, 0.13);
  color: #ffffff;
}

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

.detail-copy {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}

.detail-copy article {
  border-radius: var(--radius-lg);
  background: #ffffff;
  padding: 30px;
  box-shadow: var(--shadow-sm);
}

.detail-copy h2 {
  margin-bottom: 14px;
  font-size: 28px;
}

.detail-copy p {
  margin: 0;
  color: #334155;
  font-size: 16px;
}

.site-footer {
  margin-top: 40px;
  color: #cbd5e1;
  background: linear-gradient(135deg, #111827, #1f2937);
}

.footer-inner {
  width: min(1280px, calc(100% - 32px));
  margin: 0 auto;
  padding: 48px 0;
  display: grid;
  grid-template-columns: 1.4fr repeat(3, 1fr);
  gap: 32px;
}

.footer-brand p,
.footer-column p {
  color: #94a3b8;
}

.footer-column h2 {
  margin: 0 0 14px;
  color: #ffffff;
  font-size: 18px;
}

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

.footer-column a:hover {
  color: #60a5fa;
}

.footer-bottom {
  border-top: 1px solid rgba(148, 163, 184, 0.24);
  padding: 18px 16px;
  text-align: center;
  color: #94a3b8;
}

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

.image-empty {
  opacity: 0;
}

@media (max-width: 1100px) {
  .desktop-nav,
  .site-search-form:not(.mobile-search) {
    display: none;
  }

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

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

  .watch-layout,
  .detail-copy {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 700px) {
  .container,
  .header-inner,
  .mobile-nav,
  .footer-inner {
    width: min(100% - 24px, 1280px);
  }

  .hero-carousel {
    height: 540px;
  }

  .hero-copy h1,
  .hero-copy h2 {
    font-size: 40px;
  }

  .hero-arrow {
    display: none;
  }

  .section {
    padding: 44px 0;
  }

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

  .category-grid,
  .movie-grid,
  .compact-grid,
  .compact-list,
  .category-overview-grid,
  .footer-inner {
    grid-template-columns: 1fr;
  }

  .page-hero,
  .hot-band {
    padding: 28px;
    border-radius: 24px;
  }

  .ranking-card a {
    grid-template-columns: 44px 82px 1fr;
  }

  .ranking-action {
    display: none;
  }

  .ranking-thumb {
    width: 82px;
    height: 82px;
  }

  .movie-player {
    min-height: 220px;
    border-radius: 18px;
  }
}
