
:root {
  --bg: #f4f8fc;
  --bg-soft: #ffffff;
  --text: #0f172a;
  --muted: #64748b;
  --line: rgba(148, 163, 184, 0.22);
  --primary: #0ea5e9;
  --primary-2: #2563eb;
  --primary-3: #22c55e;
  --shadow: 0 18px 40px rgba(15, 23, 42, 0.10);
  --shadow-lg: 0 26px 60px rgba(15, 23, 42, 0.16);
  --radius: 22px;
  --radius-lg: 28px;
  --container: 1240px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(circle at top left, rgba(14,165,233,0.08), transparent 22%),
    radial-gradient(circle at top right, rgba(37,99,235,0.07), transparent 24%),
    linear-gradient(180deg, #f9fbfe 0%, #eef5fb 100%);
  color: var(--text);
  font-family: "Inter", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  line-height: 1.6;
}

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

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

button,
input,
select,
textarea {
  font: inherit;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 1200;
  backdrop-filter: blur(14px);
  background: rgba(255, 255, 255, 0.72);
  border-bottom: 1px solid rgba(148, 163, 184, 0.18);
}

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

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  letter-spacing: .02em;
  white-space: nowrap;
}

.brand-mark {
  width: 14px;
  height: 14px;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--primary), var(--primary-2));
  box-shadow: 0 0 0 6px rgba(14,165,233,.12);
}

.brand-text {
  font-size: 1.05rem;
}

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

.site-nav a {
  padding: 10px 14px;
  border-radius: 999px;
  color: #334155;
  transition: .25s ease;
}

.site-nav a:hover,
.site-nav a.active {
  color: #fff;
  background: linear-gradient(135deg, var(--primary), var(--primary-2));
  box-shadow: 0 10px 24px rgba(37,99,235,0.25);
}

.nav-toggle {
  display: none;
  width: 48px;
  height: 48px;
  border: 0;
  background: transparent;
  border-radius: 14px;
  cursor: pointer;
}

.nav-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  margin: 5px auto;
  background: #1e293b;
  border-radius: 999px;
}

.hero {
  position: relative;
  overflow: hidden;
  border-radius: 0 0 34px 34px;
  margin-bottom: 18px;
}

.hero-slider {
  position: relative;
  height: clamp(540px, 72vh, 760px);
  overflow: hidden;
}

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transform: scale(1.02);
  transition: opacity .8s ease, transform 1s ease;
  pointer-events: none;
}

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

.hero-slide__bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
}

.hero-slide__bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(8,15,28,0.88) 0%, rgba(8,15,28,0.58) 44%, rgba(8,15,28,0.14) 100%),
    linear-gradient(180deg, rgba(8,15,28,0.18), rgba(8,15,28,0.56));
}

.hero-slide__content {
  position: relative;
  z-index: 2;
  height: 100%;
  display: grid;
  align-items: center;
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(260px, 0.9fr);
  gap: 28px;
  align-items: center;
}

.hero-copy {
  color: #fff;
  max-width: 720px;
  padding: 42px 0;
}

.pills {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 18px;
}

.pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 9px 14px;
  border-radius: 999px;
  background: rgba(255,255,255,.14);
  border: 1px solid rgba(255,255,255,.16);
  backdrop-filter: blur(8px);
  color: #fff;
  font-size: .88rem;
}

.hero-title {
  margin: 0;
  font-size: clamp(2.3rem, 5vw, 4.7rem);
  line-height: 1.06;
  letter-spacing: -.02em;
  text-wrap: balance;
}

.hero-summary {
  margin: 18px 0 0;
  max-width: 56ch;
  color: rgba(226, 232, 240, 0.92);
  font-size: 1.02rem;
}

.hero-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 18px;
  color: rgba(255,255,255,.8);
  font-size: .95rem;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 26px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 13px 18px;
  border-radius: 999px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: .25s ease;
  font-weight: 700;
}

.btn-primary {
  color: #fff;
  background: linear-gradient(135deg, var(--primary), var(--primary-2));
  box-shadow: 0 16px 36px rgba(37,99,235,0.35);
}

.btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 20px 46px rgba(37,99,235,0.42);
}

.btn-ghost {
  color: #fff;
  background: rgba(255,255,255,.10);
  border-color: rgba(255,255,255,.18);
  backdrop-filter: blur(8px);
}

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

.hero-side {
  display: grid;
  gap: 14px;
  padding: 20px 0;
}

.hero-mini {
  display: grid;
  grid-template-columns: 92px minmax(0, 1fr);
  gap: 14px;
  padding: 12px;
  border-radius: 22px;
  background: rgba(255,255,255,.10);
  border: 1px solid rgba(255,255,255,.14);
  backdrop-filter: blur(16px);
  color: #fff;
  box-shadow: 0 18px 34px rgba(0, 0, 0, .18);
}

.hero-mini img {
  width: 92px;
  height: 132px;
  object-fit: cover;
  border-radius: 16px;
}

.hero-mini h3 {
  margin: 4px 0 8px;
  font-size: 1rem;
  line-height: 1.25;
}

.hero-mini p {
  margin: 0;
  color: rgba(226,232,240,.86);
  font-size: .86rem;
}

.hero-mini__meta {
  margin-top: 10px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border-radius: 999px;
  padding: 6px 10px;
  font-size: .78rem;
  background: rgba(255,255,255,.12);
  border: 1px solid rgba(255,255,255,.12);
}

.hero-controls {
  position: absolute;
  inset: auto 0 22px;
  z-index: 3;
}

.hero-dots {
  display: flex;
  justify-content: center;
  gap: 10px;
}

.hero-dot {
  width: 10px;
  height: 10px;
  border: 0;
  border-radius: 999px;
  background: rgba(255,255,255,.36);
  cursor: pointer;
  transition: .25s ease;
}

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

.hero-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 3;
  width: 48px;
  height: 48px;
  border: 0;
  border-radius: 999px;
  color: #fff;
  background: rgba(0,0,0,.28);
  backdrop-filter: blur(10px);
  cursor: pointer;
  transition: .25s ease;
}

.hero-arrow:hover {
  background: rgba(0,0,0,.45);
}

.hero-arrow.prev { left: 16px; }
.hero-arrow.next { right: 16px; }

.section {
  padding: 18px 0 34px;
}

.section.card-band {
  background: linear-gradient(180deg, rgba(255,255,255,.45), rgba(255,255,255,.92));
  border-top: 1px solid rgba(148,163,184,.14);
  border-bottom: 1px solid rgba(148,163,184,.14);
}

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

.section-title {
  margin: 0;
  font-size: clamp(1.4rem, 2.3vw, 2.1rem);
  line-height: 1.15;
}

.section-subtitle {
  margin: 6px 0 0;
  color: var(--muted);
  max-width: 72ch;
}

.section-link {
  color: var(--primary-2);
  font-weight: 700;
}

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

.movie-card {
  display: grid;
  grid-template-rows: auto 1fr;
  overflow: hidden;
  border-radius: var(--radius);
  background: rgba(255,255,255,.88);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  transition: transform .24s ease, box-shadow .24s ease, border-color .24s ease;
}

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

.movie-thumb {
  position: relative;
  aspect-ratio: 16 / 10;
  overflow: hidden;
}

.movie-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .5s ease;
}

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

.movie-badge {
  position: absolute;
  top: 12px;
  left: 12px;
  padding: 6px 10px;
  border-radius: 999px;
  color: #fff;
  font-size: .76rem;
  background: rgba(15,23,42,.62);
  backdrop-filter: blur(8px);
}

.movie-year {
  position: absolute;
  top: 12px;
  right: 12px;
  padding: 6px 10px;
  border-radius: 999px;
  color: #fff;
  font-size: .76rem;
  background: linear-gradient(135deg, var(--primary), var(--primary-2));
}

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

.movie-body h3 {
  margin: 0 0 8px;
  font-size: 1.02rem;
  line-height: 1.32;
  min-height: 2.7em;
}

.movie-body p {
  margin: 0;
  color: var(--muted);
  font-size: .92rem;
}

.movie-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  margin-top: 12px;
  color: #475569;
  font-size: .82rem;
}

.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}

.tag {
  display: inline-flex;
  align-items: center;
  padding: 6px 10px;
  border-radius: 999px;
  background: #eaf4ff;
  color: #1453a6;
  font-size: .78rem;
}

.panel {
  border-radius: var(--radius-lg);
  background: rgba(255,255,255,.84);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  justify-content: space-between;
  padding: 16px;
  border-bottom: 1px solid var(--line);
}

.search-box {
  flex: 1 1 280px;
  display: flex;
  gap: 10px;
  align-items: center;
  background: #f8fbff;
  border: 1px solid rgba(148,163,184,.22);
  border-radius: 999px;
  padding: 12px 16px;
}

.search-box input {
  border: 0;
  outline: 0;
  background: transparent;
  width: 100%;
  color: var(--text);
}

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

.filter-row select {
  min-width: 150px;
  border: 1px solid rgba(148,163,184,.22);
  background: #fff;
  border-radius: 999px;
  padding: 11px 14px;
  color: var(--text);
}

.detail-hero {
  padding: 24px 0 12px;
}

.detail-layout {
  display: grid;
  grid-template-columns: 320px minmax(0, 1fr);
  gap: 24px;
  align-items: start;
}

.detail-poster {
  border-radius: 28px;
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  background: #fff;
  border: 1px solid var(--line);
}

.detail-poster img {
  width: 100%;
  aspect-ratio: 2 / 3;
  object-fit: cover;
}

.detail-info {
  padding: 4px 0;
}

.breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: var(--muted);
  font-size: .9rem;
  margin-bottom: 12px;
}

.detail-title {
  margin: 0;
  font-size: clamp(1.8rem, 3.2vw, 3.2rem);
  line-height: 1.1;
}

.detail-summary {
  margin: 14px 0 0;
  color: #334155;
  font-size: 1.02rem;
}

.stats {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 18px 0 0;
}

.stat {
  padding: 10px 14px;
  border-radius: 999px;
  background: #eff6ff;
  color: #1d4ed8;
  border: 1px solid rgba(59,130,246,.12);
  font-size: .88rem;
}

.detail-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
}

.player-wrap {
  margin-top: 24px;
  padding: 18px;
  border-radius: 28px;
  background: rgba(255,255,255,.85);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
}

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

.player-shell video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  background: #020617;
}

.player-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  background: linear-gradient(180deg, rgba(2,6,23,.18), rgba(2,6,23,.42));
  color: #fff;
  transition: opacity .24s ease;
}

.player-overlay.hidden {
  opacity: 0;
  pointer-events: none;
}

.play-button {
  width: 86px;
  height: 86px;
  border: 0;
  border-radius: 999px;
  cursor: pointer;
  color: #fff;
  background: linear-gradient(135deg, var(--primary), var(--primary-2));
  box-shadow: 0 18px 36px rgba(37,99,235,.35);
  font-size: 1.4rem;
}

.player-tip {
  margin-top: 10px;
  color: var(--muted);
  font-size: .9rem;
}

.detail-block {
  margin-top: 24px;
  padding: 20px;
}

.detail-block h2 {
  margin: 0 0 14px;
  font-size: 1.35rem;
}

.detail-block p {
  margin: 0;
  color: #334155;
}

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

.related-grid .movie-card h3 {
  min-height: auto;
  font-size: .95rem;
}

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

.category-card {
  padding: 18px;
  border-radius: 24px;
  color: #fff;
  background: linear-gradient(135deg, #0ea5e9, #2563eb);
  box-shadow: 0 18px 42px rgba(37,99,235,.28);
  min-height: 160px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.category-card:nth-child(3n) {
  background: linear-gradient(135deg, #0f766e, #0ea5e9);
}

.category-card:nth-child(3n+1) {
  background: linear-gradient(135deg, #1d4ed8, #7c3aed);
}

.category-card:nth-child(3n+2) {
  background: linear-gradient(135deg, #2563eb, #06b6d4);
}

.category-card h3 {
  margin: 0;
  font-size: 1.15rem;
}

.category-card p {
  margin: 8px 0 0;
  color: rgba(255,255,255,.86);
  font-size: .9rem;
}

.site-footer {
  margin-top: 26px;
  padding: 30px 0 22px;
  background: linear-gradient(180deg, rgba(2,6,23,.95), rgba(15,23,42,.98));
  color: #cbd5e1;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.3fr .8fr 1fr;
  gap: 24px;
}

.footer-brand {
  color: #fff;
  font-size: 1.2rem;
  font-weight: 800;
  margin-bottom: 10px;
}

.site-footer h4 {
  margin: 0 0 10px;
  color: #fff;
}

.site-footer a {
  display: block;
  margin: 0 0 8px;
  color: #cbd5e1;
}

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

.empty-state {
  text-align: center;
  padding: 42px 20px;
  color: var(--muted);
}

.page-title-wrap {
  padding: 26px 0 10px;
}

.page-title-wrap h1 {
  margin: 0;
  font-size: clamp(1.9rem, 3vw, 3rem);
}

.page-title-wrap p {
  margin: 8px 0 0;
  color: var(--muted);
  max-width: 74ch;
}

.skeleton {
  position: relative;
  overflow: hidden;
}

.skeleton::after {
  content: "";
  position: absolute;
  inset: 0;
  transform: translateX(-100%);
  background: linear-gradient(90deg, transparent, rgba(255,255,255,.42), transparent);
  animation: shimmer 1.6s infinite;
}

@keyframes shimmer {
  100% {
    transform: translateX(100%);
  }
}

.fade-in {
  animation: fadeIn .45s ease both;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}

@media (max-width: 1100px) {
  .grid-cards,
  .related-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .category-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .hero-grid {
    grid-template-columns: 1fr;
  }
  .hero-side {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 820px) {
  .nav-toggle {
    display: block;
  }
  .site-nav {
    position: absolute;
    top: 76px;
    left: 16px;
    right: 16px;
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 4px;
    padding: 12px;
    border-radius: 22px;
    background: rgba(255,255,255,.96);
    box-shadow: var(--shadow);
    border: 1px solid var(--line);
  }
  .site-nav.open {
    display: flex;
  }
  .site-nav a {
    border-radius: 14px;
  }
  .hero-slider {
    height: auto;
    min-height: 700px;
  }
  .hero-copy {
    padding-top: 28px;
  }
  .hero-side {
    grid-template-columns: 1fr;
  }
  .section-head,
  .toolbar {
    align-items: start;
    flex-direction: column;
  }
  .detail-layout,
  .footer-grid {
    grid-template-columns: 1fr;
  }
  .grid-cards,
  .related-grid,
  .category-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 560px) {
  .container {
    width: min(var(--container), calc(100vw - 24px));
  }
  .hero-slider {
    min-height: 760px;
  }
  .grid-cards,
  .related-grid,
  .category-grid {
    grid-template-columns: 1fr;
  }
  .hero-mini {
    grid-template-columns: 80px minmax(0, 1fr);
  }
  .hero-mini img {
    width: 80px;
    height: 116px;
  }
  .movie-meta {
    flex-direction: column;
    align-items: start;
  }
}
