.page-products {
  --pp-gap: 22px;
  --pp-gap-lg: 34px;
  overflow-x: hidden;
  padding-bottom: 72px;
}

.page-products .container,
.page-products .container--wide {
  width: 100%;
}

/* ---------- 首屏 ---------- */
.page-products .product-hero {
  position: relative;
  padding: 28px 0 52px;
  background:
    radial-gradient(120% 95% at 10% -10%, rgba(139, 75, 255, .34), transparent 58%),
    radial-gradient(95% 75% at 94% 10%, rgba(43, 231, 214, .16), transparent 62%),
    var(--ink);
  border-bottom: 1px solid var(--line-soft);
}

.page-products .product-hero::after {
  content: "";
  position: absolute;
  inset: auto 0 0 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--cyan), rgba(139, 75, 255, .7), transparent);
  opacity: .6;
}

.page-products .product-hero__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--pp-gap-lg);
  margin-top: 20px;
}

.page-products .product-hero__lead .display-title {
  margin: 14px 0 18px;
  max-width: 22ch;
}

.page-products .product-hero__panel {
  padding: 18px 18px 16px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--glass);
  backdrop-filter: blur(6px);
}

.page-products .product-hero__panel-label {
  margin: 0 0 12px;
  font-size: 12px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--cyan);
}

.page-products .hero-facts {
  list-style: none;
  margin: 0;
  padding: 0;
}

.page-products .hero-facts li {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  padding: 9px 0;
  border-bottom: 1px dashed var(--line-soft);
}

.page-products .hero-facts li:last-child {
  border-bottom: 0;
}

.page-products .hero-facts__k {
  font-size: 14px;
  color: var(--mist);
}

.page-products .hero-facts__v {
  font-size: 15px;
  color: var(--sand);
}

/* ---------- 目录 ---------- */
.page-products .product-index {
  background: linear-gradient(90deg, rgba(139, 75, 255, .12), rgba(14, 59, 58, .22));
  border-bottom: 1px solid var(--line-soft);
}

.page-products .product-index__list {
  display: flex;
  align-items: center;
  gap: 6px;
  list-style: none;
  margin: 0;
  padding: 10px 0;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: thin;
}

.page-products .product-index__list > li {
  flex: 0 0 auto;
}

.page-products .product-index .index-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  white-space: nowrap;
  font-size: 14px;
}

/* ---------- 章节骨架 ---------- */
.page-products .pg-section {
  padding: 56px 0;
  background: var(--ink);
}

.page-products .pg-section--plate {
  background: linear-gradient(180deg, rgba(23, 16, 41, .72), rgba(11, 12, 18, .96));
}

.page-products .pg-section--obsidian {
  background: linear-gradient(180deg, rgba(23, 16, 41, .95), rgba(11, 12, 18, .98));
}

.page-products .pg-section--teal {
  background: linear-gradient(180deg, rgba(14, 59, 58, .62), rgba(11, 12, 18, .98));
}

.page-products .pg-section--violet {
  background:
    radial-gradient(85% 70% at 88% 0%, rgba(139, 75, 255, .24), transparent 62%),
    radial-gradient(70% 60% at 4% 90%, rgba(179, 22, 75, .18), transparent 60%),
    var(--ink);
}

.page-products .pg-section .section-head {
  margin-bottom: 26px;
}

/* ---------- 图片容器 ---------- */
.page-products .media-frame img {
  display: block;
  width: 100%;
  height: 100%;
  max-width: 100%;
  object-fit: cover;
}

.page-products .media-frame {
  margin: 0;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--line-soft);
  background: var(--obsidian);
}

/* ---------- 下载命令带 ---------- */
.page-products .dl-band {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
  margin-top: 26px;
}

.page-products .dl-key {
  position: relative;
  padding: 18px 18px 16px;
  border-radius: 12px;
  border: 1px solid rgba(43, 231, 214, .30);
  background: linear-gradient(180deg, rgba(23, 16, 41, .96), rgba(11, 12, 18, .96));
  box-shadow:
    inset 0 2px 0 rgba(245, 241, 232, .10),
    inset 0 -3px 0 rgba(0, 0, 0, .55),
    0 0 0 1px rgba(11, 12, 18, .6);
  transition: transform .18s var(--ease), border-color .18s var(--ease), box-shadow .18s var(--ease);
}

.page-products .dl-key:hover,
.page-products .dl-key:focus-within {
  transform: translateY(-2px);
  border-color: var(--cyan);
  box-shadow:
    inset 0 2px 0 rgba(245, 241, 232, .14),
    inset 0 -3px 0 rgba(0, 0, 0, .55),
    0 0 22px rgba(43, 231, 214, .22);
}

.page-products .dl-key--wide {
  border-color: rgba(255, 107, 44, .55);
}

.page-products .dl-key__label {
  margin: 0 0 8px;
  font-size: 12px;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--neon);
}

.page-products .dl-key__value {
  margin: 0 0 8px;
  font-family: var(--font-display);
  font-size: 19px;
  font-weight: 800;
  line-height: 1.35;
  color: var(--sand);
}

.page-products .dl-key__note {
  margin: 0;
  font-size: 14px;
  line-height: 1.7;
  color: var(--mist);
}

/* ---------- 安装流程 ---------- */
.page-products .install-flow {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
  margin-top: 40px;
  padding-top: 30px;
  border-top: 1px solid var(--line);
}

.page-products .install-flow__title {
  margin: 0 0 16px;
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--sand);
}

.page-products .install-flow__steps {
  list-style: none;
  margin: 0 0 18px;
  padding: 0;
  counter-reset: none;
}

.page-products .install-flow__steps li {
  display: grid;
  grid-template-columns: 40px 1fr;
  gap: 12px;
  align-items: start;
  padding: 12px 0;
  border-bottom: 1px dashed var(--line-soft);
}

.page-products .install-flow__steps li:last-child {
  border-bottom: 0;
}

.page-products .install-flow__idx {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 28px;
  border-radius: 6px;
  font-size: 13px;
  color: var(--ink);
  background: var(--cyan);
}

.page-products .install-flow__step {
  font-size: 15.5px;
  line-height: 1.7;
  color: var(--sand);
}

.page-products .install-flow__fig {
  border-radius: var(--radius);
}

/* ---------- 三类玩法拼贴 ---------- */
.page-products .mode-collage {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--pp-gap);
}

.page-products .mode-card {
  position: relative;
  padding: 24px 22px;
  border-radius: var(--radius);
  border: 1px solid var(--line-soft);
  background: var(--glass);
  backdrop-filter: blur(6px);
  transition: transform .18s var(--ease), border-color .18s var(--ease), background .18s var(--ease);
}

.page-products .mode-card:hover {
  transform: translateY(-2px);
  border-color: rgba(43, 231, 214, .55);
  background: var(--glass-strong);
}

.page-products .mode-card__kicker {
  margin: 0 0 10px;
  font-size: 12px;
  letter-spacing: .14em;
  color: var(--cyan);
}

.page-products .mode-card__title {
  margin: 0 0 12px;
  font-family: var(--font-display);
  font-size: 1.2rem;
  font-weight: 800;
  line-height: 1.4;
  color: var(--sand);
}

.page-products .mode-card p {
  margin: 0 0 14px;
  font-size: 15px;
  line-height: 1.75;
  color: rgba(245, 241, 232, .82);
}

.page-products .mode-card__list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.page-products .mode-card__list li {
  position: relative;
  padding: 7px 0 7px 18px;
  font-size: 14px;
  line-height: 1.65;
  color: var(--mist);
  border-top: 1px dashed var(--line-soft);
}

.page-products .mode-card__list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 15px;
  width: 7px;
  height: 7px;
  border-radius: 2px;
  background: var(--neon);
}

.page-products .mode-card--arcade {
  border-left: 3px solid var(--violet);
}

.page-products .mode-card--friends {
  border-left: 3px solid var(--lava);
}

.page-products .mode-card--sports {
  border-left: 3px solid var(--cyan);
}

/* ---------- 规则库 ---------- */
.page-products .rule-split {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--pp-gap-lg);
}

.page-products .rule-split__body .lede {
  margin-top: 0;
}

.page-products .rule-zones {
  list-style: none;
  margin: 26px 0 20px;
  padding: 0;
  display: grid;
  gap: 12px;
}

.page-products .rule-zone {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 6px 14px;
  padding: 16px 18px;
  border-radius: 12px;
  border: 1px solid var(--line-soft);
  background: rgba(11, 12, 18, .55);
}

.page-products .rule-zone__name {
  font-family: var(--font-serif);
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--sand);
}

.page-products .rule-zone__count {
  align-self: center;
  font-size: 12px;
  letter-spacing: .08em;
  color: var(--neon);
  border: 1px solid rgba(255, 209, 102, .45);
  border-radius: 999px;
  padding: 2px 10px;
}

.page-products .rule-zone__desc {
  grid-column: 1 / -1;
  font-size: 14px;
  line-height: 1.75;
  color: var(--mist);
}

.page-products .rule-split__fig {
  border-radius: var(--radius);
}

/* ---------- 禁手墙 ---------- */
.page-products .forbid-wall {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}

.page-products .forbid-card {
  border: 1px solid rgba(255, 209, 102, .55);
  border-radius: 12px;
  background: rgba(23, 16, 41, .72);
  overflow: hidden;
  transition: transform .18s var(--ease), border-color .18s var(--ease), background .18s var(--ease);
}

.page-products .forbid-card:hover {
  transform: translateY(-2px);
  border-color: var(--neon);
  background: rgba(23, 16, 41, .95);
}

.page-products .forbid-card[open] {
  border-color: var(--lava);
}

.page-products .forbid-card__head {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  cursor: pointer;
  list-style: none;
}

.page-products .forbid-card__head::-webkit-details-marker {
  display: none;
}

.page-products .forbid-card__head::after {
  content: "+";
  margin-left: auto;
  font-family: var(--font-mono);
  font-size: 16px;
  color: var(--neon);
  transition: transform .16s var(--ease);
}

.page-products .forbid-card[open] .forbid-card__head::after {
  content: "−";
}

.page-products .forbid-card__num {
  flex: 0 0 auto;
  min-width: 30px;
  font-size: 13px;
  color: var(--neon);
}

.page-products .forbid-card__name {
  font-size: 15.5px;
  font-weight: 700;
  color: var(--sand);
}

.page-products .forbid-card__body {
  padding: 0 16px 16px;
  border-top: 1px dashed rgba(255, 209, 102, .28);
}

.page-products .forbid-card__body p {
  margin: 12px 0 10px;
  font-size: 14px;
  line-height: 1.75;
  color: var(--mist);
}

.page-products .forbid-card__link {
  display: inline-block;
  font-size: 13.5px;
  color: var(--cyan);
  text-decoration: none;
  border-bottom: 1px solid rgba(43, 231, 214, .45);
  padding-bottom: 2px;
}

.page-products .forbid-foot {
  margin: 26px 0 0;
  padding-top: 18px;
  border-top: 1px solid var(--line);
  font-family: var(--font-serif);
  font-size: 15px;
  line-height: 1.85;
  color: rgba(245, 241, 232, .8);
}

/* ---------- 难度 ---------- */
.page-products .diff-lede {
  margin-top: 0;
  max-width: 68ch;
}

.page-products .diff-layout {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--pp-gap-lg);
  margin: 30px 0 34px;
}

.page-products .diff-rail {
  position: relative;
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
}

.page-products .diff-step {
  position: relative;
  padding: 16px 18px;
  border-radius: 12px;
  border: 1px solid var(--line-soft);
  background: rgba(11, 12, 18, .6);
  transition: border-color .18s var(--ease), background .18s var(--ease), transform .18s var(--ease);
}

.page-products .diff-step:hover {
  transform: translateY(-2px);
  border-color: rgba(43, 231, 214, .5);
}

.page-products .diff-step.is-current {
  border-color: var(--lava);
  background: linear-gradient(180deg, rgba(255, 107, 44, .14), rgba(11, 12, 18, .7));
}

.page-products .diff-step__idx {
  display: block;
  font-size: 12px;
  letter-spacing: .12em;
  color: var(--cyan);
  margin-bottom: 6px;
}

.page-products .diff-step__name {
  display: block;
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 900;
  letter-spacing: .04em;
  color: var(--sand);
  margin-bottom: 8px;
}

.page-products .diff-step__desc {
  margin: 0;
  font-size: 14px;
  line-height: 1.7;
  color: var(--mist);
}

.page-products .diff-layout__fig {
  border-radius: var(--radius);
  max-width: 420px;
}

.page-products .table-scroll {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  border: 1px solid var(--line-soft);
  border-radius: 12px;
}

.page-products .diff-table {
  width: 100%;
  min-width: 620px;
  border-collapse: collapse;
  font-size: 14.5px;
}

.page-products .diff-table caption {
  padding: 14px 16px;
  text-align: left;
  font-family: var(--font-mono);
  font-size: 12.5px;
  letter-spacing: .08em;
  color: var(--cyan);
  background: rgba(14, 59, 58, .45);
}

.page-products .diff-table th,
.page-products .diff-table td {
  padding: 12px 16px;
  text-align: left;
  border-top: 1px solid var(--line-soft);
  line-height: 1.6;
}

.page-products .diff-table thead th {
  font-size: 13px;
  font-weight: 600;
  color: var(--neon);
  letter-spacing: .04em;
  background: rgba(23, 16, 41, .7);
}

.page-products .diff-table tbody th {
  color: var(--sand);
  font-weight: 700;
  white-space: nowrap;
}

.page-products .diff-table tbody td {
  color: var(--mist);
}

.page-products .diff-table tbody tr:hover td,
.page-products .diff-table tbody tr:hover th {
  background: rgba(43, 231, 214, .06);
}

.page-products .diff-layout + .table-scroll {
  margin-bottom: 20px;
}

/* ---------- 房间 ---------- */
.page-products .room-layout {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--pp-gap-lg);
}

.page-products .room-layout__body .lede {
  margin-top: 0;
}

.page-products .room-groups {
  list-style: none;
  margin: 26px 0 24px;
  padding: 0;
  display: grid;
  gap: 12px;
}

.page-products .room-group {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 6px 14px;
  padding: 16px 18px;
  border-radius: 12px;
  background: rgba(11, 12, 18, .55);
  border: 1px solid var(--line-soft);
  border-left: 3px solid var(--violet);
}

.page-products .room-group:nth-child(2) {
  border-left-color: var(--lava);
}

.page-products .room-group:nth-child(3) {
  border-left-color: var(--cyan);
}

.page-products .room-group:nth-child(4) {
  border-left-color: var(--ruby);
}

.page-products .room-group__name {
  font-family: var(--font-serif);
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--sand);
}

.page-products .room-group__meta {
  align-self: center;
  font-size: 13px;
  color: var(--neon);
}

.page-products .room-group p {
  grid-column: 1 / -1;
  margin: 0;
  font-size: 14px;
  line-height: 1.7;
  color: var(--mist);
}

.page-products .room-params {
  list-style: none;
  margin: 0;
  padding: 0;
}

.page-products .room-params li {
  display: grid;
  grid-template-columns: 1fr;
  gap: 4px;
  padding: 12px 0;
  font-size: 14px;
  line-height: 1.7;
  color: rgba(245, 241, 232, .82);
  border-top: 1px solid var(--line-soft);
}

.page-products .room-params__k {
  font-size: 12.5px;
  letter-spacing: .08em;
  color: var(--cyan);
}

.page-products .room-layout__fig {
  border-radius: var(--radius);
}

/* ---------- 版本说明 ---------- */
.page-products .changelog-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}

.page-products .cl-col {
  padding: 20px 18px;
  border-radius: 12px;
  border: 1px solid var(--line-soft);
  background: rgba(23, 16, 41, .6);
  transition: transform .18s var(--ease), border-color .18s var(--ease);
}

.page-products .cl-col:hover {
  transform: translateY(-2px);
  border-color: rgba(43, 231, 214, .45);
}

.page-products .cl-col--accent {
  background: linear-gradient(180deg, rgba(179, 22, 75, .28), rgba(23, 16, 41, .8));
  border-color: rgba(179, 22, 75, .6);
}

.page-products .cl-col__k {
  margin: 0 0 10px;
  font-size: 12.5px;
  letter-spacing: .12em;
  color: var(--cyan);
}

.page-products .cl-col--accent .cl-col__k {
  color: var(--neon);
}

.page-products .cl-col__v {
  margin: 0;
  font-size: 14.5px;
  line-height: 1.75;
  color: rgba(245, 241, 232, .84);
}

.page-products .cl-foot {
  display: grid;
  grid-template-columns: 1fr;
  gap: 18px;
  align-items: center;
  margin-top: 28px;
  padding-top: 24px;
  border-top: 1px solid var(--line);
}

.page-products .cl-foot__text {
  margin: 0;
  font-family: var(--font-serif);
  font-size: 15px;
  line-height: 1.85;
  color: rgba(245, 241, 232, .8);
}

.page-products .cl-foot .btn {
  justify-self: start;
  text-decoration: none;
}

/* ---------- 通用链接与焦点 ---------- */
.page-products a {
  color: var(--cyan);
}

.page-products a:focus-visible,
.page-products summary:focus-visible {
  outline: 2px solid var(--cyan);
  outline-offset: 3px;
  border-radius: 4px;
}

/* ---------- 响应式 ---------- */
@media (min-width: 640px) {
  .page-products .dl-band {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .page-products .dl-key--wide {
    grid-column: 1 / -1;
  }

  .page-products .forbid-wall {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

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

  .page-products .room-params li {
    grid-template-columns: 140px 1fr;
    gap: 12px;
    align-items: baseline;
  }
}

@media (min-width: 900px) {
  .page-products .product-hero {
    padding: 36px 0 64px;
  }

  .page-products .product-hero__grid {
    grid-template-columns: minmax(0, 7fr) minmax(0, 3fr);
    align-items: end;
    gap: 46px;
  }

  .page-products .pg-section {
    padding: 76px 0;
  }

  .page-products .pg-section .section-head {
    margin-bottom: 34px;
  }

  .page-products .dl-band {
    grid-template-columns: 1.6fr 1fr 1.1fr;
  }

  .page-products .dl-key--wide {
    grid-column: auto;
  }

  .page-products .install-flow {
    grid-template-columns: minmax(0, 4fr) minmax(0, 5fr) minmax(0, 3fr);
    align-items: center;
    gap: 30px;
  }

  .page-products .install-flow__fig {
    grid-column: 3 / 4;
  }

  .page-products .mode-collage {
    grid-template-columns: repeat(12, minmax(0, 1fr));
  }

  .page-products .mode-card--arcade {
    grid-column: 1 / span 7;
  }

  .page-products .mode-card--friends {
    grid-column: 8 / span 5;
  }

  .page-products .mode-card--sports {
    grid-column: 3 / span 10;
  }

  .page-products .rule-split {
    grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
    align-items: start;
  }

  .page-products .forbid-wall {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .page-products .diff-layout {
    grid-template-columns: minmax(0, 7fr) minmax(0, 3fr);
    align-items: start;
  }

  .page-products .diff-rail {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0;
    padding-top: 46px;
  }

  .page-products .diff-rail::before {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    top: 22px;
    height: 2px;
    background: linear-gradient(90deg, var(--cyan), var(--violet) 55%, var(--lava));
    opacity: .6;
  }

  .page-products .diff-step {
    border-radius: 0;
    border: 0;
    border-left: 1px solid var(--line-soft);
    background: transparent;
    padding: 0 18px 0 16px;
  }

  .page-products .diff-step::before {
    content: "";
    position: absolute;
    left: 18px;
    top: -30px;
    width: 11px;
    height: 11px;
    border-radius: 50%;
    background: var(--obsidian);
    border: 2px solid var(--cyan);
  }

  .page-products .diff-step.is-current::before {
    background: var(--lava);
    border-color: var(--lava);
    box-shadow: 0 0 12px rgba(255, 107, 44, .7);
  }

  .page-products .diff-step:hover {
    transform: none;
    background: rgba(43, 231, 214, .05);
    border-radius: 0;
  }

  .page-products .diff-step.is-current {
    background: rgba(255, 107, 44, .08);
    border-radius: 0;
    border-left-color: rgba(255, 107, 44, .5);
  }

  .page-products .diff-layout__fig {
    justify-self: end;
  }

  .page-products .room-layout {
    grid-template-columns: minmax(0, 6fr) minmax(0, 5fr);
    align-items: start;
  }

  .page-products .changelog-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .page-products .cl-foot {
    grid-template-columns: minmax(0, 8fr) auto;
    gap: 30px;
  }

  .page-products .cl-foot .btn {
    justify-self: end;
  }
}

@media (min-width: 1200px) {
  .page-products .rule-split {
    gap: 48px;
  }

  .page-products .room-layout {
    gap: 44px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .page-products .dl-key,
  .page-products .mode-card,
  .page-products .forbid-card,
  .page-products .diff-step,
  .page-products .cl-col {
    transition: none;
  }

  .page-products .dl-key:hover,
  .page-products .mode-card:hover,
  .page-products .forbid-card:hover,
  .page-products .diff-step:hover,
  .page-products .cl-col:hover {
    transform: none;
  }
}
