:root {
  --bg: #f8fafc;
  --surface: #ffffff;
  --text: #111827;
  --muted: #6b7280;
  --line: #e5e7eb;
  --blue: #2563eb;
  --cyan: #06b6d4;
  --cyan-soft: #cffafe;
  --blue-soft: #dbeafe;
  --dark: #0f172a;
  --shadow: 0 18px 45px rgba(15, 23, 42, 0.10);
  --radius: 22px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
  color: var(--text);
  background: linear-gradient(180deg, #eff6ff 0%, #f8fafc 28%, #ffffff 100%);
  line-height: 1.65;
}

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

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

button,
input,
select {
  font: inherit;
}

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

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.88);
  backdrop-filter: blur(18px);
  border-bottom: 1px solid rgba(229, 231, 235, 0.85);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  min-height: 76px;
}

.brand,
.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

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

.brand-text strong {
  display: block;
  font-size: 24px;
  line-height: 1.05;
  color: transparent;
  background: linear-gradient(90deg, var(--blue), var(--cyan));
  -webkit-background-clip: text;
  background-clip: text;
}

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

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

.desktop-nav a:hover,
.mobile-nav a:hover {
  color: var(--blue);
}

.header-search {
  position: relative;
  display: flex;
  align-items: center;
}

.header-search input {
  width: 240px;
  border: 1px solid #d1d5db;
  border-radius: 999px;
  padding: 10px 42px 10px 16px;
  background: #ffffff;
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

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

.header-search button {
  position: absolute;
  right: 8px;
  width: 30px;
  height: 30px;
  border: 0;
  border-radius: 50%;
  color: var(--blue);
  background: #eff6ff;
  cursor: pointer;
}

.menu-toggle {
  display: none;
  border: 0;
  background: transparent;
  font-size: 26px;
  cursor: pointer;
}

.mobile-nav {
  display: none;
  border-top: 1px solid var(--line);
  padding: 16px;
  background: #ffffff;
}

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

.mobile-category-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.mobile-category-links a {
  padding: 6px 10px;
  border-radius: 999px;
  background: #eff6ff;
}

.hero-carousel {
  position: relative;
  overflow: hidden;
  color: #ffffff;
  background: linear-gradient(135deg, #1e3a8a, #0891b2);
}

.hero-shell {
  position: relative;
  min-height: 650px;
}

.hero-slide {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(260px, 0.55fr);
  align-items: center;
  gap: 46px;
  width: 100%;
  padding: 90px max(32px, calc((100vw - 1180px) / 2)) 72px;
  opacity: 0;
  pointer-events: none;
  transform: translateX(24px);
  transition: opacity 0.55s ease, transform 0.55s ease;
}

.hero-slide.is-active {
  opacity: 1;
  pointer-events: auto;
  transform: translateX(0);
}

.hero-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  background-image:
    linear-gradient(90deg, rgba(15, 23, 42, 0.88), rgba(15, 23, 42, 0.52), rgba(8, 145, 178, 0.58)),
    var(--hero-image);
  background-size: cover;
  background-position: center;
  filter: saturate(1.05);
}

.hero-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 18% 22%, rgba(59, 130, 246, 0.48), transparent 32%),
    radial-gradient(circle at 86% 20%, rgba(6, 182, 212, 0.42), transparent 28%);
}

.hero-copy,
.hero-poster {
  position: relative;
  z-index: 1;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--blue);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.hero-copy .eyebrow {
  color: #bfdbfe;
}

.hero-copy h1 {
  max-width: 760px;
  margin: 16px 0;
  font-size: clamp(42px, 7vw, 82px);
  line-height: 0.98;
  letter-spacing: -0.05em;
}

.hero-copy p {
  max-width: 720px;
  margin: 0 0 22px;
  color: rgba(255, 255, 255, 0.86);
  font-size: 18px;
}

.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;
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.16);
  color: #ffffff;
  font-size: 13px;
}

.tag-row span,
.detail-tags a {
  color: #0891b2;
  background: #ecfeff;
}

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

.primary-button,
.ghost-button,
.footer-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 22px;
  border-radius: 999px;
  font-weight: 800;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.primary-button {
  color: #ffffff;
  background: linear-gradient(135deg, var(--blue), var(--cyan));
  box-shadow: 0 16px 32px rgba(37, 99, 235, 0.25);
}

.ghost-button {
  color: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.36);
  background: rgba(255, 255, 255, 0.12);
}

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

.hero-poster {
  overflow: hidden;
  border-radius: 30px;
  min-height: 410px;
  background: linear-gradient(135deg, rgba(37, 99, 235, 0.85), rgba(6, 182, 212, 0.85));
  box-shadow: 0 28px 80px rgba(0, 0, 0, 0.34);
}

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

.hero-poster span {
  position: absolute;
  right: 18px;
  bottom: 18px;
  padding: 9px 14px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.88);
  color: #0f172a;
  font-weight: 800;
}

.image-missing::before {
  content: "";
  display: block;
  width: 100%;
  height: 100%;
  min-height: inherit;
  background:
    radial-gradient(circle at 20% 20%, rgba(255, 255, 255, 0.38), transparent 24%),
    linear-gradient(135deg, #2563eb, #06b6d4);
}

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

.hero-dot {
  width: 38px;
  height: 5px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.38);
  cursor: pointer;
}

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

.stats-strip {
  background: #ffffff;
  border-bottom: 1px solid var(--line);
}

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

.stats-grid div {
  padding: 18px;
  border-radius: 18px;
  background: linear-gradient(135deg, #eff6ff, #ecfeff);
}

.stats-grid strong {
  display: block;
  font-size: 30px;
  line-height: 1;
  color: var(--blue);
}

.stats-grid span {
  color: var(--muted);
  font-size: 14px;
}

.page-main {
  padding: 46px 0 70px;
}

.section-block {
  margin: 34px 0;
}

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

.section-heading h2,
.section-block > h2,
.page-title h1 {
  margin: 4px 0 0;
  font-size: clamp(28px, 4vw, 44px);
  line-height: 1.1;
  letter-spacing: -0.03em;
}

.section-heading a,
.text-link {
  color: var(--blue);
  font-weight: 800;
}

.search-card,
.content-card,
.category-large-card,
.filter-bar,
.table-section,
.ranking-panel {
  border: 1px solid rgba(229, 231, 235, 0.88);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.92);
  box-shadow: var(--shadow);
}

.search-card {
  padding: clamp(24px, 5vw, 44px);
  background:
    radial-gradient(circle at 82% 18%, rgba(6, 182, 212, 0.14), transparent 25%),
    linear-gradient(135deg, #ffffff, #eff6ff);
}

.big-search {
  display: flex;
  gap: 12px;
  max-width: 760px;
  margin-top: 20px;
}

.big-search input,
.filter-bar input,
.filter-bar select {
  width: 100%;
  border: 1px solid #d1d5db;
  border-radius: 14px;
  padding: 13px 15px;
  outline: none;
  background: #ffffff;
}

.big-search button {
  border: 0;
  border-radius: 14px;
  padding: 0 28px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--blue), var(--cyan));
  font-weight: 800;
  cursor: pointer;
}

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

.movie-card {
  overflow: hidden;
  border: 1px solid rgba(229, 231, 235, 0.9);
  border-radius: 22px;
  background: #ffffff;
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.08);
  transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease;
}

.movie-card:hover {
  transform: translateY(-5px);
  border-color: rgba(37, 99, 235, 0.28);
  box-shadow: 0 20px 42px rgba(37, 99, 235, 0.16);
}

.poster-link {
  position: relative;
  display: block;
  min-height: 280px;
  overflow: hidden;
  background: linear-gradient(135deg, #dbeafe, #cffafe);
}

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

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

.play-dot,
.rank-badge {
  position: absolute;
  z-index: 2;
  display: grid;
  place-items: center;
  color: #ffffff;
  background: linear-gradient(135deg, var(--blue), var(--cyan));
  box-shadow: 0 10px 22px rgba(37, 99, 235, 0.24);
}

.play-dot {
  right: 12px;
  bottom: 12px;
  width: 42px;
  height: 42px;
  border-radius: 50%;
}

.rank-badge {
  left: 12px;
  top: 12px;
  min-width: 34px;
  height: 34px;
  padding: 0 8px;
  border-radius: 999px;
  font-size: 14px;
}

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

.movie-meta-line {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  color: var(--muted);
  font-size: 13px;
}

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

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

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

.category-tile,
.category-large-card {
  overflow: hidden;
  padding: 18px;
  border-radius: 22px;
  background: #ffffff;
  box-shadow: var(--shadow);
}

.category-covers {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 5px;
  height: 74px;
  margin-bottom: 14px;
  overflow: hidden;
  border-radius: 16px;
  background: linear-gradient(135deg, #dbeafe, #cffafe);
}

.category-covers img {
  width: 100%;
  height: 74px;
  object-fit: cover;
}

.category-tile h3,
.category-large-card h2 {
  margin: 0 0 6px;
}

.category-tile p,
.category-large-card p,
.muted-text {
  color: var(--muted);
}

.category-tile span {
  color: var(--blue);
  font-weight: 800;
}

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

.category-large-card {
  padding: 0;
}

.category-large-head {
  display: block;
  padding: 26px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--blue), var(--cyan));
}

.category-large-head span {
  display: inline-flex;
  padding: 5px 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.18);
}

.mini-link-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 18px 26px 6px;
}

.mini-link-list a {
  padding: 6px 10px;
  border-radius: 999px;
  background: #eff6ff;
  color: #2563eb;
  font-size: 13px;
}

.category-large-card .text-link {
  display: inline-flex;
  padding: 12px 26px 24px;
}

.hot-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin: 0;
  padding: 22px;
  list-style: none;
}

.hot-list li {
  display: grid;
  grid-template-columns: 44px 1fr auto;
  align-items: center;
  gap: 10px;
  padding: 12px;
  border-radius: 14px;
  background: #f8fafc;
}

.hot-list b {
  color: var(--cyan);
}

.hot-list a {
  overflow: hidden;
  font-weight: 750;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.hot-list span {
  color: var(--muted);
  font-size: 13px;
}

.page-title {
  max-width: 860px;
  margin-bottom: 28px;
}

.page-title p {
  color: var(--muted);
  font-size: 17px;
}

.compact-title {
  margin-bottom: 18px;
}

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

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

.filter-bar {
  display: grid;
  grid-template-columns: 1fr 190px 190px auto;
  align-items: center;
  gap: 12px;
  padding: 16px;
  margin-bottom: 24px;
}

.filter-bar span {
  color: var(--muted);
  font-size: 14px;
  white-space: nowrap;
}

.detail-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(310px, 0.55fr);
  gap: 24px;
  align-items: start;
}

.player-box {
  position: relative;
  overflow: hidden;
  border-radius: 24px;
  background: #000000;
  box-shadow: 0 30px 70px rgba(15, 23, 42, 0.28);
  aspect-ratio: 16 / 9;
}

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

.video-play-cover {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  gap: 8px;
  border: 0;
  color: #ffffff;
  background: radial-gradient(circle, rgba(37, 99, 235, 0.22), rgba(0, 0, 0, 0.18));
  cursor: pointer;
}

.video-play-cover.is-hidden {
  display: none;
}

.video-play-cover span {
  display: grid;
  width: 74px;
  height: 74px;
  place-items: center;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--blue), var(--cyan));
  box-shadow: 0 16px 36px rgba(37, 99, 235, 0.35);
}

.detail-info-card {
  padding: 24px;
  border-radius: 24px;
  background: #ffffff;
  box-shadow: var(--shadow);
}

.detail-info-card h1 {
  margin: 8px 0 12px;
  font-size: clamp(28px, 4vw, 44px);
  line-height: 1.08;
}

.one-line {
  color: #374151;
  font-size: 16px;
}

.info-list {
  display: grid;
  gap: 12px;
  margin: 22px 0;
}

.info-list div {
  display: grid;
  grid-template-columns: 64px 1fr;
  gap: 12px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--line);
}

.info-list dt {
  color: var(--muted);
}

.info-list dd {
  margin: 0;
  font-weight: 750;
}

.detail-content-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 22px;
  margin: 28px 0;
}

.content-card {
  padding: 24px;
}

.content-card h2 {
  margin-top: 0;
}

.table-wrap {
  overflow-x: auto;
}

table {
  width: 100%;
  border-collapse: collapse;
  background: #ffffff;
}

th,
td {
  padding: 13px 14px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  white-space: nowrap;
}

th {
  color: #374151;
  background: #f8fafc;
}

td a {
  color: var(--blue);
  font-weight: 750;
}

.inline-button {
  margin-top: 12px;
}

.site-footer {
  color: #d1d5db;
  background: #111827;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.35fr 1fr 1fr 1fr;
  gap: 30px;
  padding: 48px 0;
}

.site-footer h3,
.site-footer strong {
  color: #ffffff;
}

.site-footer p,
.site-footer a {
  color: #9ca3af;
}

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

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

.footer-button {
  margin-top: 12px;
  color: #ffffff !important;
  background: linear-gradient(135deg, var(--blue), var(--cyan));
}

.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 18px 0;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  color: #9ca3af;
}

.back-to-top {
  border: 0;
  color: #93c5fd;
  background: transparent;
  cursor: pointer;
}

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

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

  .menu-toggle {
    display: block;
  }

  .hero-slide,
  .detail-hero,
  .detail-content-grid,
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .hero-slide {
    position: relative;
    display: none;
    min-height: 760px;
  }

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

  .hero-shell {
    min-height: auto;
  }

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

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

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

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

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

  .hero-slide {
    min-height: 720px;
    padding: 48px 18px 68px;
  }

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

  .hero-poster,
  .hero-poster img {
    min-height: 280px;
    height: 300px;
  }

  .big-search,
  .section-heading,
  .footer-bottom {
    align-items: stretch;
    flex-direction: column;
  }

  .big-search button {
    min-height: 48px;
  }

  .movie-grid,
  .category-grid,
  .category-large-grid,
  .stats-grid,
  .hot-list,
  .filter-bar {
    grid-template-columns: 1fr;
  }

  .poster-link,
  .poster-link img {
    min-height: 250px;
    height: 250px;
  }
}
