:root {
  color-scheme: dark;
  font-family: "Microsoft YaHei UI", "PingFang SC", "Noto Sans SC", Arial, sans-serif;
  --bg: #050507;
  --panel: #111115;
  --panel-2: #19191f;
  --ink: #fff7ea;
  --muted: #a9a39a;
  --line: rgba(255,247,234,.12);
  --red: #e31f2f;
  --gold: #f6b94c;
  --blue: #2d76ff;
  --green: #1fc78c;
  --shadow: 0 28px 80px rgba(0,0,0,.5);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  background:
    radial-gradient(circle at 12% 12%, rgba(227,31,47,.28), transparent 28rem),
    radial-gradient(circle at 88% 8%, rgba(45,118,255,.18), transparent 28rem),
    linear-gradient(180deg, #08080b 0%, #050507 62%, #090809 100%);
}
a { color: inherit; text-decoration: none; }
img { display: block; width: 100%; }
h1, h2, h3, p, figure { margin-top: 0; }
button, select { font: inherit; }

.masthead {
  position: fixed;
  left: 18px;
  top: 18px;
  bottom: 18px;
  z-index: 30;
  width: 236px;
  padding: 16px;
  display: grid;
  grid-template-rows: auto 1fr;
  gap: 24px;
  background: rgba(17,17,21,.88);
  border: 1px solid var(--line);
  border-radius: 26px;
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
}
.brand {
  min-height: 106px;
  padding: 18px;
  display: grid;
  align-content: end;
  background:
    linear-gradient(135deg, rgba(227,31,47,.96), rgba(91,24,31,.92)),
    var(--red);
  border-radius: 20px;
}
.brand strong {
  font-size: 1.85rem;
  line-height: 1;
}
.brand span {
  margin-top: 8px;
  color: #ffe2a6;
  font-size: .78rem;
  font-weight: 950;
}
.masthead nav {
  display: grid;
  align-content: start;
  gap: 8px;
  overflow-y: auto;
  scrollbar-width: none;
}
.masthead nav a {
  min-height: 44px;
  padding: 0 14px;
  display: flex;
  align-items: center;
  color: var(--muted);
  border: 1px solid transparent;
  border-radius: 14px;
  font-weight: 900;
}
.masthead nav a.active,
.masthead nav a:hover {
  color: var(--ink);
  background: rgba(255,247,234,.1);
  border-color: rgba(255,247,234,.22);
}
.masthead nav a.active {
  color: #070707;
  background: var(--gold);
}

.magazine,
.footer {
  width: min(1540px, calc(100% - 292px));
  margin-left: 274px;
  margin-right: 18px;
}
.magazine {
  padding: 18px 0 34px;
  display: grid;
  gap: 18px;
}
.cover {
  min-height: 720px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  grid-template-rows: auto minmax(0, 1fr);
  gap: 18px;
}
.cover-label,
.cover-copy,
.cover-poster,
.cover-note,
.section,
.library-cover,
.filter-strip,
.detail-stage,
.footer {
  background: linear-gradient(180deg, rgba(25,25,31,.92), rgba(12,12,15,.96));
  border: 1px solid var(--line);
  border-radius: 26px;
  box-shadow: var(--shadow);
}
.cover-label {
  grid-column: 1 / -1;
  min-height: 58px;
  padding: 0 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  background: rgba(255,247,234,.08);
}
.cover-label p {
  margin: 0;
  color: var(--gold);
  font-weight: 950;
}
.cover-label b {
  color: var(--muted);
  font-size: .86rem;
}
.cover-copy {
  padding: clamp(28px, 5vw, 78px);
  display: grid;
  align-content: end;
  position: relative;
  overflow: hidden;
}
.cover-copy::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(227,31,47,.16), transparent 48%),
    repeating-linear-gradient(90deg, rgba(255,247,234,.055) 0 1px, transparent 1px 42px);
  pointer-events: none;
}
.cover-copy > * { position: relative; }
.eyebrow {
  margin-bottom: 10px;
  color: var(--gold);
  font-size: .76rem;
  font-weight: 950;
  letter-spacing: 0;
  text-transform: uppercase;
}
h1 {
  max-width: 900px;
  margin-bottom: 16px;
  font-size: clamp(2.65rem, 6.2vw, 6.6rem);
  line-height: .94;
}
h2 {
  margin-bottom: 0;
  font-size: clamp(1.3rem, 2.1vw, 2.1rem);
  line-height: 1.1;
}
h3 { line-height: 1.18; }
.cover-copy p,
.cover-note p,
.section p,
.library-cover p,
.detail-copy p,
.footer p,
.rank-row small {
  color: var(--muted);
  line-height: 1.74;
}
.hero-stats {
  margin: 10px 0 22px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 140px));
  gap: 10px;
}
.hero-stats span {
  padding: 12px;
  background: rgba(255,247,234,.08);
  border: 1px solid var(--line);
  border-radius: 16px;
  color: var(--muted);
  font-size: .82rem;
  font-weight: 900;
}
.hero-stats b {
  display: block;
  color: var(--ink);
  font-size: 1.55rem;
}
.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}
.action,
.ghost {
  min-height: 44px;
  padding: 0 18px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 14px;
  font-weight: 950;
}
.action {
  color: #08080b;
  background: var(--gold);
}
.ghost {
  color: var(--ink);
  background: rgba(255,247,234,.08);
  border: 1px solid var(--line);
}
.cover-poster {
  grid-column: 2;
  grid-row: 2 / 4;
  padding: 12px;
}
.cover-poster a {
  position: relative;
  display: block;
  height: 100%;
  min-height: 630px;
  overflow: hidden;
  border-radius: 20px;
}
.cover-poster img {
  height: 100%;
  object-fit: cover;
}
.cover-poster span {
  position: absolute;
  left: 14px;
  right: 14px;
  bottom: 14px;
  padding: 12px 14px;
  color: #08080b;
  background: var(--gold);
  border-radius: 14px;
  font-weight: 950;
}
.cover-note {
  min-height: 240px;
  padding: clamp(22px, 3vw, 40px);
  display: grid;
  align-content: center;
  border-left: 4px solid var(--red);
}
.cover-note h2 {
  font-size: clamp(1.65rem, 3vw, 2.65rem);
}

.channel-rail {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 14px;
}
.channel-rail a {
  min-height: 126px;
  padding: 12px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 64px;
  gap: 12px;
  align-items: center;
  background: rgba(255,247,234,.07);
  border: 1px solid var(--line);
  border-radius: 22px;
}
.channel-rail strong {
  display: block;
  margin-bottom: 6px;
  font-size: 1.08rem;
}
.channel-rail span {
  color: var(--muted);
  font-size: .84rem;
}
.channel-rail img {
  width: 64px;
  height: 90px;
  object-fit: cover;
  border-radius: 14px;
}

.paper-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 18px;
}
.section {
  padding: clamp(16px, 2vw, 24px);
}
.section-head {
  margin-bottom: 18px;
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 14px;
}
.section-head a {
  color: var(--gold);
  font-weight: 950;
}
.poster-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 14px;
}
.mixed-grid {
  grid-template-columns: repeat(8, minmax(0, 1fr));
}
.poster-card,
.strip-card {
  background: rgba(255,247,234,.065);
  border: 1px solid var(--line);
  border-radius: 18px;
  overflow: hidden;
  transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease;
}
.poster-card:hover,
.strip-card:hover {
  transform: translateY(-6px);
  border-color: rgba(246,185,76,.58);
  box-shadow: 0 18px 42px rgba(0,0,0,.32);
}
.poster-card a { display: grid; }
.poster-card figure,
.strip-card figure {
  position: relative;
  margin: 0;
  background: #15151a;
}
.poster-card img {
  aspect-ratio: 3 / 4.2;
  object-fit: cover;
}
.poster-card figcaption,
.strip-card figcaption {
  position: absolute;
  top: 9px;
  right: 9px;
  padding: 5px 8px;
  color: #08080b;
  background: var(--gold);
  border-radius: 999px;
  font-size: .78rem;
  font-weight: 950;
}
.poster-card div {
  min-height: 112px;
  padding: 11px;
}
.poster-card span,
.strip-card span {
  color: var(--gold);
  font-size: .76rem;
  font-weight: 950;
}
.poster-card h3,
.strip-card h3 {
  margin: 6px 0 5px;
  font-size: .98rem;
}
.poster-card p,
.strip-card p {
  margin-bottom: 7px;
  color: var(--muted);
  font-size: .82rem;
}
.poster-card em,
.strip-card em {
  color: var(--green);
  font-style: normal;
  font-size: .8rem;
  font-weight: 950;
}

.rank-row {
  min-height: 58px;
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr) 44px;
  gap: 10px;
  align-items: center;
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
}
.rank-row b {
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  color: #08080b;
  background: var(--gold);
  border-radius: 10px;
  font-size: .75rem;
}
.rank-row span {
  min-width: 0;
  display: grid;
  gap: 2px;
  font-weight: 950;
}
.rank-row small {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.rank-row i {
  justify-self: end;
  color: var(--red);
  font-style: normal;
  font-weight: 950;
}
.strip-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}
.strip-card a {
  display: grid;
  grid-template-columns: 88px minmax(0, 1fr);
}
.strip-card img {
  height: 126px;
  object-fit: cover;
}
.strip-card div { padding: 11px; }

.library-cover {
  min-height: 330px;
  padding: clamp(28px, 5vw, 72px);
  display: grid;
  grid-template-columns: minmax(0, 1fr) 220px;
  gap: 24px;
  align-items: end;
}
.library-cover h1 {
  font-size: clamp(2.45rem, 5.4vw, 5.8rem);
}
.library-cover strong {
  padding: 18px;
  color: #08080b;
  background: var(--gold);
  border-radius: 18px;
  font-size: 1.6rem;
}
.filter-strip {
  padding: 14px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 210px;
  gap: 12px;
  align-items: center;
}
.filters {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.filters button,
.filter-strip select {
  min-height: 38px;
  padding: 0 13px;
  color: var(--ink);
  background: rgba(255,247,234,.08);
  border: 1px solid var(--line);
  border-radius: 14px;
  font-weight: 950;
}
.filters button.active {
  color: #08080b;
  background: var(--gold);
}
.filter-strip label {
  display: grid;
  gap: 5px;
  color: var(--muted);
  font-weight: 950;
}
.library-grid {
  grid-template-columns: repeat(7, minmax(0, 1fr));
}
.library-grid .strip-card {
  grid-column: span 2;
}

.detail-stage {
  min-height: 640px;
  display: grid;
  grid-template-columns: minmax(300px, .46fr) minmax(0, 1fr);
  gap: clamp(18px, 3vw, 44px);
  padding: clamp(16px, 2vw, 24px);
}
.detail-poster {
  margin: 0;
  background: #15151a;
  border-radius: 22px;
  overflow: hidden;
}
.detail-poster img {
  height: 100%;
  min-height: 580px;
  object-fit: cover;
}
.detail-copy {
  padding: clamp(24px, 5vw, 66px);
  display: grid;
  align-content: center;
}
.detail-copy h1 {
  font-size: clamp(2.45rem, 5vw, 5.4rem);
}
.sub {
  color: var(--gold) !important;
  font-size: 1.08rem;
  font-weight: 950;
}
.facts {
  margin: 16px 0;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.facts span {
  padding: 8px 11px;
  color: #08080b;
  background: var(--gold);
  border-radius: 14px;
  font-weight: 950;
}
.related-grid {
  grid-template-columns: repeat(6, minmax(0, 1fr));
}

.footer {
  margin-top: 0;
  margin-bottom: 28px;
  padding: 24px;
  display: grid;
  grid-template-columns: 1.4fr repeat(3, 1fr);
  gap: 18px;
}
.footer strong { font-size: 1.4rem; }
.footer h3 {
  margin-bottom: 8px;
  color: var(--gold);
}
.footer a {
  display: block;
  margin: 5px 0;
  color: var(--muted);
  font-weight: 900;
}

@media (max-width: 1280px) {
  .masthead {
    position: sticky;
    left: auto;
    top: 12px;
    bottom: auto;
    width: min(100% - 24px, 1180px);
    margin: 12px auto 0;
    grid-template-columns: 200px minmax(0, 1fr);
    grid-template-rows: auto;
  }
  .masthead nav {
    display: flex;
    overflow-x: auto;
  }
  .magazine,
  .footer {
    width: min(1180px, calc(100% - 24px));
    margin-left: auto;
    margin-right: auto;
  }
  .cover,
  .paper-layout,
  .library-cover,
  .detail-stage {
    grid-template-columns: 1fr;
  }
  .cover-poster {
    grid-column: auto;
    grid-row: auto;
  }
  .poster-grid,
  .mixed-grid,
  .library-grid,
  .related-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
  .channel-rail,
  .strip-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 760px) {
  .masthead {
    grid-template-columns: 1fr;
    border-radius: 22px;
  }
  .brand { min-height: 72px; }
  .cover-label {
    align-items: flex-start;
    flex-direction: column;
    gap: 8px;
    padding-block: 14px;
  }
  .filter-strip,
  .hero-stats {
    grid-template-columns: 1fr;
  }
  .poster-grid,
  .mixed-grid,
  .library-grid,
  .related-grid,
  .channel-rail,
  .strip-grid,
  .footer {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  h1 { font-size: 2.7rem; }
}

@media (max-width: 520px) {
  .magazine,
  .footer {
    width: calc(100% - 20px);
  }
  .poster-grid,
  .mixed-grid,
  .library-grid,
  .related-grid,
  .channel-rail,
  .strip-grid,
  .footer {
    grid-template-columns: 1fr;
  }
  .cover-copy,
  .library-cover,
  .detail-copy {
    padding: 22px;
  }
  .cover-poster a,
  .detail-poster img {
    min-height: 420px;
  }
}
