:root {
  --bg: #f9fafb;
  --panel: #ffffff;
  --text: #111827;
  --muted: #6b7280;
  --line: #e5e7eb;
  --blue: #2563eb;
  --blue-dark: #1e40af;
  --blue-soft: #dbeafe;
  --orange: #f97316;
  --green: #16a34a;
  --shadow: 0 10px 25px rgba(15, 23, 42, 0.08);
  --shadow-lg: 0 20px 45px rgba(15, 23, 42, 0.16);
  --radius: 18px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--bg);
  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 {
  display: block;
  max-width: 100%;
}

button,
input,
select {
  font: inherit;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.92);
  border-bottom: 1px solid rgba(229, 231, 235, 0.86);
  box-shadow: 0 8px 25px rgba(15, 23, 42, 0.06);
  backdrop-filter: blur(18px);
}

.nav-wrap {
  min-height: 68px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 22px;
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--blue);
  font-size: 22px;
  font-weight: 800;
  letter-spacing: -0.02em;
  white-space: nowrap;
}

.logo-mark {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: linear-gradient(135deg, #3b82f6, #1d4ed8);
  color: #ffffff;
  box-shadow: 0 10px 20px rgba(37, 99, 235, 0.26);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 20px;
  color: #374151;
  font-weight: 650;
}

.nav-links a {
  transition: color 0.2s ease;
}

.nav-links a:hover {
  color: var(--blue);
}

.nav-search {
  position: relative;
  width: 245px;
  flex: 0 0 auto;
}

.nav-search input {
  width: 100%;
  height: 40px;
  padding: 0 44px 0 18px;
  border: 1px solid #d1d5db;
  border-radius: 999px;
  outline: none;
  color: #1f2937;
  background: #ffffff;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.nav-search input:focus {
  border-color: var(--blue);
  box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.12);
}

.nav-search button {
  position: absolute;
  top: 50%;
  right: 10px;
  width: 30px;
  height: 30px;
  transform: translateY(-50%);
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: #6b7280;
  cursor: pointer;
}

.menu-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 12px;
  background: #eff6ff;
  color: var(--blue);
  cursor: pointer;
}

.hero-slider {
  position: relative;
  min-height: 500px;
  background: linear-gradient(90deg, #172554, #1d4ed8);
  overflow: hidden;
}

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

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

.hero-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.32;
  transform: scale(1.02);
}

.hero-shade {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 76% 24%, rgba(96, 165, 250, 0.32), transparent 38%),
    linear-gradient(90deg, rgba(15, 23, 42, 0.84), rgba(30, 64, 175, 0.62), rgba(30, 64, 175, 0.30));
}

.hero-inner {
  position: relative;
  z-index: 2;
  min-height: 500px;
  display: flex;
  align-items: center;
}

.hero-copy {
  width: min(680px, 100%);
  color: #ffffff;
}

.hero-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 18px;
  padding: 7px 14px;
  border-radius: 999px;
  background: rgba(37, 99, 235, 0.92);
  color: #ffffff;
  font-size: 14px;
  font-weight: 750;
  box-shadow: 0 10px 22px rgba(37, 99, 235, 0.28);
}

.hero-copy h1,
.hero-copy h2 {
  margin: 0 0 18px;
  color: #ffffff;
  font-size: clamp(38px, 6vw, 60px);
  line-height: 1.08;
  letter-spacing: -0.04em;
  font-weight: 850;
}

.hero-copy p {
  margin: 0 0 28px;
  max-width: 650px;
  color: #e5e7eb;
  font-size: 18px;
}

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

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 22px;
  border: 0;
  border-radius: 999px;
  cursor: pointer;
  font-weight: 750;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease, color 0.2s ease;
}

.btn:hover {
  transform: translateY(-1px);
}

.btn-primary {
  background: var(--blue);
  color: #ffffff;
  box-shadow: 0 14px 26px rgba(37, 99, 235, 0.25);
}

.btn-primary:hover {
  background: var(--blue-dark);
}

.btn-light {
  background: #ffffff;
  color: var(--blue);
}

.btn-light:hover {
  background: #eff6ff;
}

.btn-ghost {
  background: rgba(255, 255, 255, 0.16);
  color: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.28);
}

.hero-arrow {
  position: absolute;
  top: 50%;
  z-index: 4;
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  transform: translateY(-50%);
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.18);
  color: #ffffff;
  cursor: pointer;
  transition: background 0.2s ease, transform 0.2s ease;
}

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

.hero-arrow.prev {
  left: 24px;
}

.hero-arrow.next {
  right: 24px;
}

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

.hero-dot {
  width: 9px;
  height: 9px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.55);
  cursor: pointer;
  transition: width 0.25s ease, background 0.25s ease;
}

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

.main-section {
  padding: 54px 0;
}

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

.section-title {
  display: flex;
  align-items: center;
  gap: 12px;
}

.section-icon {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  background: var(--blue-soft);
  color: var(--blue);
}

.section-title h2,
.section-title h1 {
  margin: 0;
  font-size: clamp(25px, 3vw, 34px);
  line-height: 1.2;
  letter-spacing: -0.03em;
}

.section-subtitle {
  margin: 8px 0 0;
  color: var(--muted);
}

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

.movie-card {
  min-width: 0;
  background: var(--panel);
  border: 1px solid rgba(229, 231, 235, 0.78);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.06);
  transition: transform 0.28s ease, box-shadow 0.28s ease, border-color 0.28s ease;
}

.movie-card.is-hidden {
  display: none;
}

.movie-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
  border-color: rgba(37, 99, 235, 0.30);
}

.poster-wrap {
  position: relative;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: #e5e7eb;
}

.poster-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.35s ease;
}

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

.poster-mask {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  background: rgba(0, 0, 0, 0);
  color: #ffffff;
  opacity: 0;
  transition: opacity 0.25s ease, background 0.25s ease;
}

.movie-card:hover .poster-mask,
.list-card:hover .poster-mask,
.related-card:hover .poster-mask {
  opacity: 1;
  background: rgba(0, 0, 0, 0.30);
}

.poster-play {
  width: 56px;
  height: 56px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.92);
  color: var(--blue);
  font-size: 20px;
}

.duration {
  position: absolute;
  right: 9px;
  bottom: 9px;
  padding: 3px 8px;
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.72);
  color: #ffffff;
  font-size: 12px;
  font-weight: 700;
}

.card-body {
  padding: 16px;
}

.card-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 10px;
  color: #6b7280;
  font-size: 12px;
}

.badge {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 0 9px;
  border-radius: 999px;
  background: #eff6ff;
  color: #1d4ed8;
  font-size: 12px;
  font-weight: 750;
}

.movie-card h3,
.list-card h3 {
  margin: 0 0 8px;
  color: #111827;
  font-size: 17px;
  line-height: 1.35;
  transition: color 0.2s ease;
}

.movie-card:hover h3,
.list-card:hover h3,
.related-card:hover h4 {
  color: var(--blue);
}

.card-desc {
  display: -webkit-box;
  min-height: 44px;
  margin: 0 0 12px;
  overflow: hidden;
  color: #6b7280;
  font-size: 14px;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.card-foot {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  color: #6b7280;
  font-size: 12px;
}

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

.category-tile {
  position: relative;
  min-height: 160px;
  padding: 24px;
  overflow: hidden;
  border-radius: 22px;
  background: linear-gradient(135deg, #3b82f6, #1d4ed8);
  color: #ffffff;
  box-shadow: 0 14px 30px rgba(37, 99, 235, 0.22);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.category-tile::after {
  content: "";
  position: absolute;
  right: -36px;
  bottom: -46px;
  width: 150px;
  height: 150px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.18);
}

.category-tile:hover {
  transform: translateY(-4px) scale(1.01);
  box-shadow: 0 22px 42px rgba(37, 99, 235, 0.28);
}

.category-tile h3 {
  position: relative;
  z-index: 1;
  margin: 0 0 8px;
  font-size: 22px;
}

.category-tile p {
  position: relative;
  z-index: 1;
  margin: 0 0 18px;
  color: #dbeafe;
  font-size: 14px;
}

.category-tile span {
  position: relative;
  z-index: 1;
  font-weight: 750;
}

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

.list-card {
  display: flex;
  gap: 16px;
  padding: 14px;
  border: 1px solid rgba(229, 231, 235, 0.82);
  border-radius: 18px;
  background: #ffffff;
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.06);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

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

.list-card .poster-wrap {
  width: 190px;
  flex: 0 0 auto;
  border-radius: 12px;
}

.list-card-body {
  min-width: 0;
  flex: 1;
}

.list-card p {
  display: -webkit-box;
  margin: 0 0 12px;
  overflow: hidden;
  color: #6b7280;
  font-size: 14px;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.cta-panel {
  padding: 42px 28px;
  border-radius: 26px;
  background: linear-gradient(90deg, #2563eb, #1d4ed8);
  color: #ffffff;
  text-align: center;
  box-shadow: 0 16px 38px rgba(37, 99, 235, 0.26);
}

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

.cta-panel p {
  max-width: 760px;
  margin: 0 auto 24px;
  color: #dbeafe;
}

.page-hero {
  padding: 52px 0;
  background:
    radial-gradient(circle at 80% 20%, rgba(59, 130, 246, 0.26), transparent 30%),
    linear-gradient(135deg, #172554, #1d4ed8);
  color: #ffffff;
}

.page-hero h1 {
  margin: 0 0 12px;
  font-size: clamp(34px, 5vw, 52px);
  line-height: 1.12;
  letter-spacing: -0.04em;
}

.page-hero p {
  max-width: 820px;
  margin: 0;
  color: #dbeafe;
  font-size: 17px;
}

.breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 9px;
  margin-bottom: 18px;
  color: #64748b;
  font-size: 14px;
}

.breadcrumbs a:hover {
  color: var(--blue);
}

.filter-panel {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px;
  margin-bottom: 26px;
  padding: 18px;
  border: 1px solid rgba(229, 231, 235, 0.90);
  border-radius: 20px;
  background: #ffffff;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.05);
}

.filter-panel input,
.filter-panel select {
  height: 44px;
  min-width: 200px;
  padding: 0 14px;
  border: 1px solid #d1d5db;
  border-radius: 12px;
  outline: none;
  background: #ffffff;
  color: #111827;
}

.filter-panel input:focus,
.filter-panel select:focus {
  border-color: var(--blue);
  box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.12);
}

.empty-state {
  display: none;
  padding: 34px;
  border-radius: 20px;
  background: #ffffff;
  color: #6b7280;
  text-align: center;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.05);
}

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

.detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(300px, 1fr);
  gap: 28px;
}

.panel {
  border: 1px solid rgba(229, 231, 235, 0.82);
  border-radius: 20px;
  background: #ffffff;
  box-shadow: var(--shadow);
  overflow: hidden;
}

.panel-pad {
  padding: 24px;
}

.video-panel {
  margin-bottom: 24px;
}

.player {
  position: relative;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border-radius: 20px;
  background: #000000;
}

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

.player-cover {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  background: rgba(17, 24, 39, 0.30);
  cursor: pointer;
  transition: opacity 0.25s ease, visibility 0.25s ease;
}

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

.player-start {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-height: 58px;
  padding: 0 24px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.94);
  color: var(--blue);
  font-weight: 850;
  cursor: pointer;
  box-shadow: 0 16px 32px rgba(0, 0, 0, 0.22);
}

.player-start span:first-child {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: var(--blue);
  color: #ffffff;
}

.player-message {
  position: absolute;
  left: 50%;
  bottom: 18px;
  display: none;
  width: min(90%, 420px);
  padding: 12px 16px;
  transform: translateX(-50%);
  border-radius: 12px;
  background: rgba(17, 24, 39, 0.82);
  color: #ffffff;
  text-align: center;
}

.player.has-message .player-message {
  display: block;
}

.detail-title {
  margin: 0 0 16px;
  font-size: clamp(28px, 4vw, 38px);
  line-height: 1.18;
  letter-spacing: -0.03em;
}

.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 20px;
  color: #6b7280;
  font-size: 14px;
}

.tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  margin-bottom: 22px;
}

.tag {
  display: inline-flex;
  min-height: 28px;
  align-items: center;
  padding: 0 11px;
  border-radius: 999px;
  background: #f3f4f6;
  color: #4b5563;
  font-size: 13px;
}

.article-block h2 {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 12px;
  color: #111827;
  font-size: 22px;
}

.article-block h2::before {
  content: "";
  width: 5px;
  height: 24px;
  border-radius: 999px;
  background: var(--blue);
}

.article-block p {
  margin: 0;
  color: #374151;
  line-height: 1.85;
}

.side-panel {
  position: sticky;
  top: 92px;
}

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

.related-card {
  display: flex;
  gap: 12px;
  min-width: 0;
}

.related-card .poster-wrap {
  width: 130px;
  flex: 0 0 auto;
  border-radius: 12px;
}

.related-card h4 {
  display: -webkit-box;
  margin: 0 0 8px;
  overflow: hidden;
  color: #111827;
  font-size: 15px;
  line-height: 1.35;
  transition: color 0.2s ease;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.related-card p {
  margin: 0;
  color: #6b7280;
  font-size: 12px;
}

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

.rank-item {
  display: grid;
  grid-template-columns: 54px 1fr auto;
  gap: 14px;
  align-items: center;
  padding: 14px;
  border-radius: 16px;
  background: #ffffff;
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.06);
}

.rank-num {
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  background: linear-gradient(135deg, #f97316, #ef4444);
  color: #ffffff;
  font-weight: 850;
}

.rank-item h3 {
  margin: 0 0 4px;
  font-size: 17px;
}

.rank-item p {
  margin: 0;
  color: #6b7280;
  font-size: 13px;
}

.site-footer {
  margin-top: 48px;
  padding: 42px 0;
  background: #111827;
  color: #d1d5db;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 28px;
}

.footer-title {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 14px;
  color: #ffffff;
  font-size: 20px;
  font-weight: 800;
}

.footer-grid h3 {
  margin: 0 0 14px;
  color: #ffffff;
  font-size: 16px;
}

.footer-grid p,
.footer-grid a {
  color: #9ca3af;
  font-size: 14px;
}

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

.footer-links {
  display: grid;
  gap: 8px;
}

.copyright {
  margin-top: 28px;
  padding-top: 22px;
  border-top: 1px solid rgba(156, 163, 175, 0.20);
  color: #6b7280;
  font-size: 13px;
}

@media (max-width: 1024px) {
  .movie-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

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

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

  .side-panel {
    position: static;
  }

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

  .nav-search {
    width: 210px;
  }
}

@media (max-width: 860px) {
  .menu-toggle {
    display: grid;
    place-items: center;
  }

  .nav-links {
    position: absolute;
    left: 16px;
    right: 16px;
    top: 76px;
    display: none;
    padding: 18px;
    border: 1px solid rgba(229, 231, 235, 0.95);
    border-radius: 18px;
    background: #ffffff;
    box-shadow: var(--shadow-lg);
  }

  .nav-links.is-open {
    display: grid;
    gap: 12px;
  }

  .nav-links .nav-search {
    width: 100%;
  }

  .hero-arrow {
    display: none;
  }

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

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

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

  .list-grid {
    grid-template-columns: 1fr;
  }

  .list-card .poster-wrap {
    width: 150px;
  }

  .filter-panel input,
  .filter-panel select {
    min-width: 0;
    width: 100%;
  }
}

@media (max-width: 560px) {
  .container {
    width: min(100% - 24px, 1180px);
  }

  .logo {
    font-size: 18px;
  }

  .logo-mark {
    width: 32px;
    height: 32px;
  }

  .hero-slider,
  .hero-inner {
    min-height: 520px;
  }

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

  .main-section {
    padding: 38px 0;
  }

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

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

  .list-card {
    flex-direction: column;
  }

  .list-card .poster-wrap {
    width: 100%;
  }

  .related-card .poster-wrap {
    width: 110px;
  }

  .rank-item {
    grid-template-columns: 42px 1fr;
  }

  .rank-item .btn {
    grid-column: 1 / -1;
  }

  .footer-grid {
    grid-template-columns: 1fr;
  }
}
