:root {
  --primary-50: #e6f2f8;
  --primary-100: #cce5f1;
  --primary-400: #3397c7;
  --primary-600: #006494;
  --primary-700: #004b6f;
  --primary-800: #00324a;
  --secondary-600: #147494;
  --accent-50: #fef9e7;
  --accent-500: #f5c30f;
  --accent-600: #c49c0c;
  --neutral-50: #f8f9fa;
  --neutral-100: #f1f3f5;
  --neutral-200: #e9ecef;
  --neutral-300: #dee2e6;
  --neutral-500: #adb5bd;
  --neutral-700: #495057;
  --neutral-800: #343a40;
  --neutral-900: #212529;
  --shadow-soft: 0 2px 15px rgba(0, 0, 0, .08);
  --shadow-strong: 0 8px 30px rgba(0, 0, 0, .18);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
  color: var(--neutral-900);
  background: var(--neutral-50);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--neutral-50);
  color: var(--neutral-900);
}

body.is-menu-open {
  overflow: hidden;
}

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

img {
  display: block;
  width: 100%;
  height: auto;
}

button,
input,
select {
  font: inherit;
}

main {
  min-height: 70vh;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, .94);
  box-shadow: var(--shadow-soft);
  backdrop-filter: blur(16px);
}

.header-inner {
  max-width: 1280px;
  height: 76px;
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  align-items: center;
  gap: 24px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-width: 192px;
}

.brand-icon {
  width: 38px;
  height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--primary-600), var(--secondary-600));
  box-shadow: var(--shadow-soft);
}

.brand-text {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
}

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

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

.main-nav {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 28px;
}

.nav-link {
  color: var(--neutral-700);
  font-weight: 600;
  transition: color .2s ease;
}

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

.header-search,
.mobile-search,
.hero-search {
  display: flex;
  align-items: center;
  background: #ffffff;
  border: 1px solid var(--neutral-200);
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 1px 8px rgba(0, 0, 0, .05);
}

.header-search input,
.mobile-search input,
.hero-search input {
  min-width: 210px;
  border: 0;
  outline: 0;
  padding: 12px 14px;
  background: transparent;
}

.header-search button,
.mobile-search button,
.hero-search button {
  border: 0;
  padding: 12px 16px;
  color: #ffffff;
  background: var(--primary-600);
  cursor: pointer;
  transition: background .2s ease;
}

.header-search button:hover,
.mobile-search button:hover,
.hero-search button:hover {
  background: var(--primary-700);
}

.menu-toggle {
  display: none;
  border: 0;
  width: 42px;
  height: 42px;
  border-radius: 10px;
  background: var(--neutral-100);
  color: var(--neutral-800);
  cursor: pointer;
}

.mobile-nav {
  display: none;
  padding: 14px 24px 24px;
  border-top: 1px solid var(--neutral-200);
  background: #ffffff;
}

.mobile-nav a {
  display: block;
  padding: 12px 8px;
  color: var(--neutral-700);
  font-weight: 600;
}

.hero {
  position: relative;
  overflow: hidden;
  background: linear-gradient(135deg, var(--primary-600), var(--secondary-600));
  color: #ffffff;
}

.hero-bg {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 15% 20%, rgba(245, 195, 15, .35), transparent 28%),
    radial-gradient(circle at 80% 10%, rgba(255, 255, 255, .16), transparent 30%),
    linear-gradient(135deg, rgba(0, 50, 74, .5), rgba(0, 100, 148, .2));
}

.hero-inner {
  position: relative;
  max-width: 1280px;
  min-height: 660px;
  margin: 0 auto;
  padding: 72px 24px 48px;
}

.hero-slide {
  display: none;
  align-items: center;
  gap: 56px;
  min-height: 430px;
}

.hero-slide.is-active {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(320px, .75fr);
  animation: fadeIn .45s ease;
}

.eyebrow {
  margin: 0 0 12px;
  color: var(--accent-500);
  font-weight: 800;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.hero h1,
.page-hero h1,
.detail-copy h1 {
  margin: 0;
  font-size: clamp(38px, 5vw, 72px);
  line-height: 1.05;
  letter-spacing: -0.06em;
}

.hero-summary {
  max-width: 680px;
  margin: 22px 0;
  color: var(--primary-50);
  font-size: 18px;
  line-height: 1.85;
}

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

.hero-tags span,
.tag-row span,
.detail-tags a {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 5px 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, .14);
  color: inherit;
  font-size: 13px;
  font-weight: 600;
}

.tag-row span {
  color: var(--primary-700);
  background: var(--primary-50);
}

.detail-tags a {
  color: var(--primary-700);
  background: var(--primary-50);
}

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

.primary-button,
.ghost-button,
.outline-button,
.section-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 20px;
  border-radius: 12px;
  font-weight: 800;
  transition: transform .2s ease, background .2s ease, color .2s ease, border-color .2s ease;
}

.primary-button {
  background: #ffffff;
  color: var(--primary-700);
}

.primary-button:hover,
.ghost-button:hover,
.outline-button:hover,
.section-link:hover {
  transform: translateY(-2px);
}

.ghost-button {
  color: #ffffff;
  background: rgba(0, 50, 74, .46);
  backdrop-filter: blur(10px);
}

.outline-button,
.section-link {
  color: var(--primary-700);
  border: 1px solid var(--primary-100);
  background: #ffffff;
}

.hero-poster {
  position: relative;
  display: block;
  overflow: hidden;
  border-radius: 28px;
  box-shadow: var(--shadow-strong);
  aspect-ratio: 3 / 4;
  isolation: isolate;
}

.hero-poster img {
  height: 100%;
  object-fit: cover;
  transform: scale(1.02);
  transition: transform .45s ease;
}

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

.hero-poster::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0, 0, 0, .56), transparent 56%);
}

.play-mark,
.player-button {
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: 2;
  width: 72px;
  height: 72px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(0, 100, 148, .88);
  box-shadow: var(--shadow-strong);
  transform: translate(-50%, -50%);
}

.hero-tools {
  display: grid;
  grid-template-columns: minmax(280px, 480px) 1fr auto;
  gap: 22px;
  align-items: center;
  margin-top: 34px;
}

.hero-search input {
  min-width: 0;
  width: 100%;
}

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

.hero-category-links a {
  padding: 9px 13px;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(255, 255, 255, .14);
}

.hero-category-links a:hover {
  background: rgba(255, 255, 255, .24);
}

.hero-control-row {
  display: flex;
  align-items: center;
  gap: 10px;
}

.hero-arrow,
.hero-dot {
  border: 0;
  color: #ffffff;
  cursor: pointer;
}

.hero-arrow {
  width: 42px;
  height: 42px;
  border-radius: 999px;
  background: rgba(0, 50, 74, .48);
  font-size: 28px;
}

.hero-dots {
  display: flex;
  gap: 8px;
}

.hero-dot {
  width: 10px;
  height: 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, .4);
}

.hero-dot.is-active {
  width: 30px;
  background: var(--accent-500);
}

.intro-section,
.content-section,
.category-showcase {
  max-width: 1280px;
  margin: 0 auto;
  padding: 58px 24px;
}

.intro-section {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
}

.intro-copy h2,
.section-heading h2,
.article-card h2 {
  margin: 0;
  font-size: clamp(26px, 3vw, 38px);
  line-height: 1.2;
  letter-spacing: -0.04em;
}

.intro-copy p:last-child,
.section-heading p,
.article-card p {
  max-width: 760px;
  color: var(--neutral-700);
  line-height: 1.85;
}

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

.soft-section,
.category-overview-block {
  max-width: none;
  background: var(--neutral-100);
}

.soft-section > .section-heading,
.soft-section > .movie-grid,
.category-overview-block > .section-heading,
.category-overview-block > .category-grid {
  max-width: 1280px;
  margin-left: auto;
  margin-right: auto;
}

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

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

.movie-card {
  overflow: hidden;
  border-radius: 18px;
  background: #ffffff;
  box-shadow: var(--shadow-soft);
  transition: transform .2s ease, box-shadow .2s ease;
}

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

.poster-link {
  position: relative;
  display: block;
  aspect-ratio: 3 / 4;
  overflow: hidden;
  background: var(--neutral-200);
}

.poster-link img {
  height: 100%;
  object-fit: cover;
  transition: transform .35s ease;
}

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

.poster-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0, 0, 0, .42), transparent 52%);
}

.movie-type,
.rank-badge {
  position: absolute;
  z-index: 2;
  border-radius: 999px;
  color: #ffffff;
  font-size: 12px;
  font-weight: 800;
}

.movie-type {
  left: 12px;
  top: 12px;
  padding: 6px 10px;
  background: rgba(0, 100, 148, .88);
}

.rank-badge {
  right: 12px;
  top: 12px;
  min-width: 32px;
  height: 32px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--accent-600);
}

.movie-info {
  padding: 16px;
}

.movie-meta {
  display: flex;
  gap: 8px;
  color: var(--neutral-500);
  font-size: 13px;
  font-weight: 700;
}

.movie-info h3 {
  margin: 8px 0 8px;
  font-size: 18px;
  line-height: 1.35;
}

.movie-info h3 a:hover {
  color: var(--primary-600);
}

.movie-info p {
  min-height: 48px;
  margin: 0 0 14px;
  color: var(--neutral-700);
  font-size: 14px;
  line-height: 1.7;
}

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

.category-card {
  padding: 22px;
  border-radius: 18px;
  background: #ffffff;
  box-shadow: var(--shadow-soft);
}

.category-card-title {
  display: inline-block;
  margin-bottom: 10px;
  color: var(--primary-700);
  font-size: 20px;
  font-weight: 900;
}

.category-card p {
  color: var(--neutral-700);
  line-height: 1.7;
}

.category-mini-links {
  display: grid;
  gap: 8px;
  margin-top: 16px;
}

.category-mini-links a {
  color: var(--neutral-700);
  font-size: 14px;
}

.category-mini-links a:hover {
  color: var(--primary-600);
}

.page-hero,
.detail-hero {
  max-width: 1280px;
  margin: 0 auto;
  padding: 64px 24px;
}

.page-hero {
  min-height: 320px;
  display: flex;
  align-items: center;
  border-radius: 0 0 28px 28px;
  color: #ffffff;
  background:
    radial-gradient(circle at 80% 10%, rgba(245, 195, 15, .26), transparent 28%),
    linear-gradient(135deg, var(--primary-600), var(--secondary-600));
}

.page-hero p {
  max-width: 760px;
  color: var(--primary-50);
  font-size: 18px;
  line-height: 1.8;
}

.slim-hero {
  min-height: 260px;
}

.filter-panel {
  padding-top: 34px;
  padding-bottom: 24px;
}

.filter-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 180px;
  gap: 14px;
  margin-bottom: 18px;
}

.filter-row input,
.filter-row select {
  width: 100%;
  border: 1px solid var(--neutral-300);
  border-radius: 12px;
  padding: 14px 16px;
  background: #ffffff;
  outline: 0;
}

.filter-row input:focus,
.filter-row select:focus {
  border-color: var(--primary-600);
  box-shadow: 0 0 0 4px rgba(0, 100, 148, .12);
}

.chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.chip {
  border: 1px solid var(--primary-100);
  padding: 9px 14px;
  border-radius: 999px;
  color: var(--primary-700);
  background: #ffffff;
  cursor: pointer;
  font-weight: 800;
}

.chip.is-active,
.chip:hover {
  color: #ffffff;
  background: var(--primary-600);
  border-color: var(--primary-600);
}

.empty-state {
  display: none;
  margin: 32px 0 0;
  padding: 24px;
  border-radius: 16px;
  background: #ffffff;
  color: var(--neutral-700);
  text-align: center;
}

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

.detail-hero {
  display: grid;
  grid-template-columns: 320px minmax(0, 1fr);
  gap: 42px;
  align-items: center;
}

.detail-poster {
  overflow: hidden;
  border-radius: 24px;
  box-shadow: var(--shadow-strong);
  aspect-ratio: 3 / 4;
}

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

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 18px;
  color: var(--neutral-500);
  font-size: 14px;
}

.breadcrumb a:hover {
  color: var(--primary-600);
}

.detail-one-line {
  margin: 20px 0;
  color: var(--neutral-700);
  font-size: 18px;
  line-height: 1.85;
}

.player-section {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 24px 40px;
}

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

.movie-player video {
  display: block;
  width: 100%;
  height: 100%;
  background: #000000;
}

.player-cover {
  position: absolute;
  inset: 0;
  z-index: 3;
  display: block;
  border: 0;
  padding: 0;
  color: #ffffff;
  background: #000000;
  cursor: pointer;
}

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

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

.player-cover-shade {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, .46);
}

.article-card {
  padding: 32px;
  border-radius: 22px;
  background: #ffffff;
  box-shadow: var(--shadow-soft);
}

.article-card h2 + p {
  margin-top: 12px;
}

.detail-meta-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  margin-top: 24px;
}

.detail-meta-grid div {
  padding: 16px;
  border-radius: 14px;
  background: var(--neutral-100);
}

.detail-meta-grid strong,
.detail-meta-grid span,
.detail-meta-grid a {
  display: block;
}

.detail-meta-grid strong {
  margin-bottom: 8px;
  color: var(--neutral-500);
  font-size: 13px;
}

.detail-meta-grid a {
  color: var(--primary-700);
  font-weight: 800;
}

.site-footer {
  margin-top: 40px;
  color: var(--neutral-300);
  background: var(--neutral-900);
}

.footer-inner {
  max-width: 1280px;
  margin: 0 auto;
  padding: 44px 24px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, .8fr);
  gap: 28px;
}

.footer-brand {
  color: #ffffff;
  font-size: 24px;
  font-weight: 900;
}

.footer-inner p {
  max-width: 640px;
  color: var(--neutral-300);
  line-height: 1.8;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  align-content: start;
  gap: 12px;
}

.footer-links a {
  padding: 8px 12px;
  border: 1px solid var(--neutral-800);
  border-radius: 999px;
}

.footer-links a:hover {
  color: #ffffff;
  border-color: var(--primary-400);
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 1120px) {
  .header-search {
    display: none;
  }

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

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

  .hero-tools {
    grid-template-columns: 1fr;
  }
}

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

  .menu-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-left: auto;
  }

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

  .header-inner {
    height: 68px;
  }

  .hero-inner {
    min-height: auto;
    padding-top: 46px;
  }

  .hero-slide.is-active,
  .detail-hero,
  .footer-inner,
  .intro-section {
    grid-template-columns: 1fr;
  }

  .hero-slide {
    gap: 28px;
  }

  .hero-poster {
    max-width: 340px;
  }

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

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

  .filter-row,
  .detail-meta-grid {
    grid-template-columns: 1fr;
  }

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

@media (max-width: 560px) {
  .header-inner,
  .hero-inner,
  .intro-section,
  .content-section,
  .category-showcase,
  .page-hero,
  .detail-hero,
  .player-section {
    padding-left: 16px;
    padding-right: 16px;
  }

  .brand {
    min-width: 0;
  }

  .brand-text small {
    display: none;
  }

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

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

  .hero-actions,
  .intro-actions {
    flex-direction: column;
  }

  .hero-search,
  .mobile-search {
    flex-direction: column;
    align-items: stretch;
  }

  .hero-search button,
  .mobile-search button {
    width: 100%;
  }

  .player-section {
    padding-bottom: 24px;
  }

  .article-card {
    padding: 22px;
  }
}
