/* ===== 首页 · page-home ===== */

.page-home {
  --ph-line: rgba(38, 52, 79, .85);
  background: var(--ink-950);
  color: var(--paper);
  overflow-x: hidden;
}

/* ---------- 首屏框景 ---------- */

.page-home .ph-hero {
  position: relative;
  padding: 30px 0 52px;
  border-bottom: var(--bd);
  background:
    radial-gradient(120% 82% at 12% 0%, rgba(51, 208, 222, .10), transparent 62%),
    radial-gradient(90% 72% at 96% 14%, rgba(225, 58, 70, .13), transparent 64%),
    var(--ink-950);
}

.page-home .ph-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(var(--ph-line) 1px, transparent 1px),
    linear-gradient(90deg, var(--ph-line) 1px, transparent 1px);
  background-size: 68px 68px;
  opacity: .3;
  pointer-events: none;
  -webkit-mask-image: linear-gradient(180deg, rgba(0, 0, 0, .95), transparent 88%);
  mask-image: linear-gradient(180deg, rgba(0, 0, 0, .95), transparent 88%);
}

.page-home .ph-hero-wrap {
  position: relative;
  z-index: 1;
}

.page-home .ph-crumbs {
  font-size: 12px;
  letter-spacing: .08em;
  color: var(--paper-faint);
  text-transform: uppercase;
}

.page-home .ph-crumbs a {
  color: var(--mist);
  text-decoration: none;
}

.page-home .ph-crumbs a:hover {
  color: var(--cyan);
}

.page-home .ph-crumbs span[aria-hidden] {
  margin: 0 8px;
  color: var(--ink-600);
}

.page-home .ph-frame {
  position: relative;
  margin-top: 18px;
  padding: 22px 18px 26px;
  border: var(--bd);
  background: linear-gradient(160deg, rgba(24, 36, 62, .78), rgba(10, 17, 32, .58));
}

.page-home .ph-frame::before {
  content: "";
  position: absolute;
  inset: -10px;
  pointer-events: none;
  background:
    linear-gradient(var(--cyan), var(--cyan)) 0 0 / 18px 1px no-repeat,
    linear-gradient(var(--cyan), var(--cyan)) 0 0 / 1px 18px no-repeat,
    linear-gradient(var(--cyan), var(--cyan)) 100% 0 / 18px 1px no-repeat,
    linear-gradient(var(--cyan), var(--cyan)) 100% 0 / 1px 18px no-repeat,
    linear-gradient(var(--cyan), var(--cyan)) 0 100% / 18px 1px no-repeat,
    linear-gradient(var(--cyan), var(--cyan)) 0 100% / 1px 18px no-repeat,
    linear-gradient(var(--cyan), var(--cyan)) 100% 100% / 18px 1px no-repeat,
    linear-gradient(var(--cyan), var(--cyan)) 100% 100% / 1px 18px no-repeat;
  opacity: .55;
}

.page-home .ph-frame::after {
  content: "";
  position: absolute;
  inset: 5px;
  border: 1px solid rgba(243, 239, 228, .07);
  pointer-events: none;
}

.page-home .ph-hero-grid {
  display: grid;
  gap: 30px;
}

.page-home .ph-hero-lead h1 {
  margin: 12px 0 0;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(36px, 9.4vw, 74px);
  line-height: .98;
  letter-spacing: -.02em;
  color: var(--paper);
}

.page-home .ph-hero-sub {
  max-width: 46ch;
  margin: 18px 0 0;
  font-size: 16px;
  line-height: 1.78;
  color: var(--paper-dim);
}

.page-home .ph-hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 22px;
}

.page-home .ph-path {
  display: block;
  width: 100%;
  max-width: 340px;
  height: 34px;
  margin-top: 26px;
  overflow: visible;
}

.page-home .ph-path-line {
  stroke: var(--cyan);
  stroke-width: 1;
  stroke-dasharray: 5 6;
  opacity: .6;
}

.page-home .ph-path-node {
  fill: var(--ink-950);
  stroke: var(--cyan);
  stroke-width: 1.5;
}

.page-home .ph-path-node--last {
  stroke: var(--gold);
  fill: var(--gold-soft);
}

.page-home .ph-hero-index {
  position: relative;
}

.page-home .ph-hero-art {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border: var(--bd);
  filter: saturate(.75) contrast(1.02);
}

.page-home .ph-index-panel {
  position: relative;
  margin: -44px 0 0 12px;
  padding: 16px 16px 10px;
  background: var(--ink-900);
  border: var(--bd);
  border-left: 3px solid var(--jbo-red);
  box-shadow: 8px 8px 0 rgba(10, 17, 32, .78);
}

.page-home .ph-index-list {
  margin: 10px 0 0;
}

.page-home .ph-index-list > div {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  padding: 9px 0;
  border-bottom: 1px dashed var(--ink-600);
}

.page-home .ph-index-list > div:last-child {
  border-bottom: 0;
}

.page-home .ph-index-list dt {
  font-size: 13px;
  color: var(--mist);
}

.page-home .ph-index-list dd {
  margin: 0;
  font-size: 14px;
  color: var(--paper);
  font-weight: 600;
}

.page-home .ph-index-list dd.mono {
  font-family: var(--font-mono);
  letter-spacing: .03em;
}

.page-home .ph-gold {
  color: var(--gold);
  text-decoration: underline;
  text-decoration-color: rgba(228, 180, 90, .45);
  text-underline-offset: 4px;
}

/* ---------- 三步路径带 ---------- */

.page-home .ph-steps {
  padding: 52px 0 44px;
  border-bottom: var(--bd);
  background: linear-gradient(180deg, var(--ink-900), var(--ink-950));
}

.page-home .ph-steps-head h2 {
  margin: 10px 0 0;
  font-family: var(--font-display);
  font-size: clamp(24px, 5.6vw, 36px);
  font-weight: 700;
  line-height: 1.12;
  letter-spacing: -.01em;
  color: var(--paper);
}

.page-home .ph-steps-lede {
  max-width: 52ch;
  margin: 12px 0 0;
  font-size: 15px;
  line-height: 1.78;
  color: var(--paper-faint);
}

.page-home .ph-steps-list {
  list-style: none;
  margin: 28px 0 0;
  padding: 0;
}

.page-home .ph-step {
  padding: 20px 0 22px;
  border-top: 1px solid var(--ink-600);
}

.page-home .ph-step-num {
  display: inline-block;
  padding-bottom: 2px;
  font-size: 13px;
  letter-spacing: .12em;
  color: var(--gold);
  border-bottom: 1px solid rgba(228, 180, 90, .45);
}

.page-home .ph-step h3 {
  margin: 12px 0 0;
  font-size: 18px;
  font-weight: 700;
  color: var(--paper);
}

.page-home .ph-step p {
  max-width: 44ch;
  margin: 8px 0 14px;
  font-size: 15px;
  line-height: 1.76;
  color: var(--paper-dim);
}

.page-home .ph-chip {
  font-size: 12px;
  letter-spacing: .06em;
  color: var(--cyan);
  border-color: rgba(51, 208, 222, .4);
  background: var(--cyan-soft);
}

.page-home .ph-steps-foot {
  margin: 22px 0 0;
  font-size: 15px;
  line-height: 1.78;
  color: var(--paper-faint);
}

.page-home .ph-steps-foot a {
  color: var(--cyan);
  text-decoration: none;
  border-bottom: 1px solid rgba(51, 208, 222, .4);
}

.page-home .ph-steps-foot a:hover {
  color: var(--paper);
}

/* ---------- Bento 信息板 ---------- */

.page-home .ph-board {
  padding: 52px 0;
  border-bottom: var(--bd);
  background: var(--ink-950);
}

.page-home .ph-board-head h2 {
  margin: 10px 0 0;
  font-family: var(--font-display);
  font-size: clamp(24px, 5.6vw, 36px);
  font-weight: 700;
  line-height: 1.12;
  color: var(--paper);
}

.page-home .ph-board-head p {
  max-width: 54ch;
  margin: 12px 0 0;
  font-size: 15px;
  line-height: 1.78;
  color: var(--paper-faint);
}

.page-home .ph-bento {
  display: grid;
  gap: 16px;
  margin-top: 28px;
}

.page-home .ph-cell {
  position: relative;
  padding: 22px 18px;
  background: var(--ink-900);
  border: var(--bd);
}

.page-home .ph-cell-title {
  margin: 0;
  font-size: 19px;
  font-weight: 700;
  line-height: 1.3;
}

.page-home .ph-cell-text {
  margin: 10px 0 0;
  font-size: 15px;
  line-height: 1.76;
}

.page-home .ph-cell-foot {
  margin: 16px 0 0;
  font-size: 14px;
  line-height: 1.7;
}

.page-home .ph-cell-link {
  display: inline-block;
  margin-top: 8px;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  border-bottom: 1px solid currentColor;
}

.page-home .ph-cell-link span {
  margin-left: 4px;
}

.page-home .ph-cell--docs {
  background: linear-gradient(152deg, var(--paper-2), #d5cebb);
  border-color: #c9c1ac;
  color: var(--ink-950);
  box-shadow: 6px 6px 0 rgba(38, 52, 79, .6), 12px 12px 0 rgba(38, 52, 79, .25);
}

.page-home .ph-cell--docs .ph-cell-title {
  color: var(--ink-950);
}

.page-home .ph-cell--docs .ph-cell-text,
.page-home .ph-cell--docs .ph-cell-foot {
  color: rgba(10, 17, 32, .78);
}

.page-home .ph-cell--docs .ph-cell-link {
  color: var(--red-700);
}

.page-home .ph-cell-art {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  margin-bottom: 16px;
  border: 1px solid rgba(10, 17, 32, .28);
}

.page-home .ph-cat-list {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 16px 0 0;
  padding: 0;
}

.page-home .ph-cat-list li {
  padding: 5px 11px;
  font-size: 13px;
  color: var(--ink-950);
  background: rgba(243, 239, 228, .62);
  border: 1px solid rgba(10, 17, 32, .3);
}

.page-home .ph-cell--version {
  background: linear-gradient(158deg, var(--ink-800), var(--ink-900));
  border-color: rgba(225, 58, 70, .5);
  border-left: 3px solid var(--jbo-red);
  color: var(--paper);
}

.page-home .ph-cell--version .ph-cell-title {
  color: var(--paper);
  font-family: var(--font-display);
  font-size: 24px;
  letter-spacing: -.01em;
}

.page-home .ph-cell--version .ph-cell-title .mono {
  font-family: var(--font-mono);
  font-size: 19px;
  color: var(--gold);
  letter-spacing: .03em;
}

.page-home .ph-cell--version .ph-cell-text {
  color: var(--paper-dim);
}

.page-home .ph-cell--version .ph-cell-foot {
  color: var(--paper-faint);
}

.page-home .ph-cell--version .ph-cell-link {
  color: var(--cyan);
}

.page-home .ph-label-red {
  color: var(--jbo-red);
}

.page-home .ph-bullets {
  list-style: none;
  margin: 16px 0 0;
  padding: 0;
}

.page-home .ph-bullets li {
  display: flex;
  gap: 10px;
  padding: 8px 0;
  font-size: 14px;
  line-height: 1.6;
  color: var(--paper-dim);
  border-top: 1px dashed var(--ink-600);
}

.page-home .ph-bullets li:first-child {
  border-top: 0;
}

.page-home .ph-bullets .mono {
  flex: 0 0 auto;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: .08em;
}

.page-home .ph-cell--search {
  background: linear-gradient(150deg, rgba(51, 208, 222, .1), var(--ink-900) 70%);
  border-color: rgba(51, 208, 222, .32);
}

.page-home .ph-cell--search .ph-cell-title {
  color: var(--paper);
}

.page-home .ph-cell--search .ph-cell-text {
  color: var(--paper-dim);
}

.page-home .ph-cell--adapter .ph-cell-title {
  color: var(--paper);
}

.page-home .ph-cell--adapter .ph-cell-text {
  color: var(--paper-dim);
}

.page-home .ph-cell--adapter {
  background:
    linear-gradient(150deg, rgba(228, 180, 90, .09), transparent 62%),
    var(--ink-900);
  border-color: rgba(228, 180, 90, .3);
}

/* ---------- 设备横带 ---------- */

.page-home .ph-devices {
  padding: 52px 0;
  border-bottom: var(--bd);
  background: linear-gradient(180deg, var(--ink-900), var(--ink-800));
}

.page-home .ph-devices-wrap {
  display: grid;
  gap: 28px;
}

.page-home .ph-devices-figure {
  margin: 0;
  border: var(--bd);
  background: var(--ink-950);
  box-shadow: 8px 8px 0 rgba(10, 17, 32, .6);
}

.page-home .ph-devices-figure img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 3 / 2;
  object-fit: cover;
  filter: saturate(.8);
}

.page-home .ph-devices-figure figcaption {
  padding: 10px 14px;
  font-size: 12px;
  letter-spacing: .06em;
  color: var(--mist);
  border-top: 1px solid var(--ink-600);
}

.page-home .ph-devices-main h2 {
  margin: 10px 0 0;
  font-family: var(--font-display);
  font-size: clamp(24px, 5.6vw, 34px);
  font-weight: 700;
  line-height: 1.14;
  color: var(--paper);
}

.page-home .ph-devices-lede {
  max-width: 52ch;
  margin: 12px 0 0;
  font-size: 15px;
  line-height: 1.78;
  color: var(--paper-dim);
}

.page-home .ph-device-list {
  list-style: none;
  display: grid;
  gap: 12px;
  margin: 22px 0 0;
  padding: 0;
}

.page-home .ph-device-list li {
  padding: 14px 16px 16px;
  background: rgba(10, 17, 32, .58);
  border: 1px solid var(--ink-600);
  border-top: 2px solid var(--cyan);
}

.page-home .ph-device-list h3 {
  margin: 0;
  font-size: 16px;
  font-weight: 700;
  color: var(--paper);
}

.page-home .ph-device-req {
  margin: 6px 0 8px;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: .04em;
  color: var(--gold);
}

.page-home .ph-device-list p:last-child {
  margin: 0;
  font-size: 14px;
  line-height: 1.7;
  color: var(--paper-faint);
}

/* ---------- 诊断索引 ---------- */

.page-home .ph-diag {
  padding: 52px 0;
  border-bottom: var(--bd);
  background: var(--ink-950);
}

.page-home .ph-diag-grid {
  display: grid;
  gap: 28px;
}

.page-home .ph-diag-intro h2 {
  margin: 10px 0 0;
  font-family: var(--font-display);
  font-size: clamp(24px, 5.6vw, 34px);
  font-weight: 700;
  line-height: 1.14;
  color: var(--paper);
}

.page-home .ph-diag-intro p {
  max-width: 46ch;
  margin: 12px 0 0;
  font-size: 15px;
  line-height: 1.78;
  color: var(--paper-dim);
}

.page-home .ph-diag-note {
  padding: 12px 14px;
  font-size: 14px;
  color: var(--paper-faint);
  background: var(--cyan-soft);
  border-left: 3px solid var(--cyan);
}

.page-home .ph-diag-item {
  margin-bottom: 10px;
  background: var(--ink-900);
  border: var(--bd);
  transition: background var(--t), border-color var(--t);
}

.page-home .ph-diag-item[open] {
  background: var(--ink-800);
  border-color: rgba(51, 208, 222, .42);
}

.page-home .ph-diag-item summary {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 15px 16px;
  font-size: 16px;
  font-weight: 600;
  color: var(--paper);
  cursor: pointer;
  list-style: none;
}

.page-home .ph-diag-item summary::-webkit-details-marker {
  display: none;
}

.page-home .ph-diag-item summary::after {
  content: "+";
  margin-left: auto;
  font-family: var(--font-mono);
  font-size: 18px;
  line-height: 1;
  color: var(--cyan);
  transition: transform var(--t-fast);
}

.page-home .ph-diag-item[open] summary::after {
  content: "-";
  transform: rotate(180deg);
}

.page-home .ph-diag-coord {
  flex: 0 0 auto;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: .08em;
  color: var(--gold);
}

.page-home .ph-diag-body {
  padding: 2px 16px 16px 16px;
  border-top: 1px dashed var(--ink-600);
}

.page-home .ph-diag-body p {
  margin: 12px 0 0;
  font-size: 15px;
  line-height: 1.76;
  color: var(--paper-dim);
}

.page-home .ph-diag-body .ph-cell-link {
  color: var(--cyan);
}

/* ---------- 最近更新 ---------- */

.page-home .ph-updates {
  padding: 0 0 60px;
  background: var(--ink-950);
}

.page-home .ph-updates-band {
  position: relative;
  border-bottom: var(--bd);
}

.page-home .ph-updates-band img {
  display: block;
  width: 100%;
  height: 170px;
  object-fit: cover;
  filter: saturate(.6) brightness(.8);
}

.page-home .ph-updates-band-cap {
  position: absolute;
  left: 14px;
  bottom: 12px;
  margin: 0;
  padding: 5px 10px;
  font-size: 12px;
  letter-spacing: .06em;
  color: var(--paper);
  background: rgba(10, 17, 32, .82);
  border: 1px solid var(--ink-600);
}

.page-home .ph-updates-head {
  margin-top: 30px;
}

.page-home .ph-updates-head h2 {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(22px, 5.2vw, 30px);
  font-weight: 700;
  line-height: 1.16;
  color: var(--paper);
}

.page-home .ph-updates-head p {
  margin: 10px 0 0;
  font-size: 15px;
  color: var(--paper-faint);
}

.page-home .ph-update-list {
  list-style: none;
  margin: 22px 0 0;
  padding: 0;
}

.page-home .ph-update-item {
  border-top: 1px solid var(--ink-600);
}

.page-home .ph-update-item a {
  display: grid;
  grid-template-columns: auto 1fr;
  grid-template-areas:
    "tag time"
    "title title";
  align-items: center;
  gap: 8px 12px;
  padding: 15px 6px 15px 0;
  color: var(--paper);
  text-decoration: none;
  transition: transform var(--t-fast), background var(--t-fast);
}

.page-home .ph-update-item a:hover,
.page-home .ph-update-item a:focus-visible {
  transform: translateX(4px);
  background: rgba(51, 208, 222, .06);
}

.page-home .ph-chip-tag {
  grid-area: tag;
  justify-self: start;
  font-size: 12px;
  letter-spacing: .08em;
  color: var(--paper);
  background: rgba(225, 58, 70, .16);
  border-color: rgba(225, 58, 70, .5);
}

.page-home .ph-update-title {
  grid-area: title;
  font-size: 15px;
  line-height: 1.62;
  color: var(--paper-dim);
}

.page-home .ph-update-time {
  grid-area: time;
  justify-self: start;
  font-size: 12px;
  letter-spacing: .06em;
  color: var(--mist);
}

.page-home .ph-updates-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 22px;
  margin-top: 22px;
  padding-top: 18px;
  border-top: 1px dashed var(--ink-600);
}

.page-home .ph-updates-links a {
  font-size: 14px;
  font-weight: 600;
  color: var(--cyan);
  text-decoration: none;
  border-bottom: 1px solid rgba(51, 208, 222, .35);
}

.page-home .ph-updates-links a:hover {
  color: var(--paper);
}

/* ---------- 断点 ---------- */

@media (min-width: 640px) {
  .page-home .ph-index-panel {
    margin-left: 22px;
  }

  .page-home .ph-device-list {
    grid-template-columns: repeat(2, 1fr);
  }

  .page-home .ph-updates-band img {
    height: 220px;
  }

  .page-home .ph-update-item a {
    grid-template-columns: auto 1fr auto;
    grid-template-areas: "tag title time";
  }
}

@media (min-width: 900px) {
  .page-home .ph-hero {
    padding: 44px 0 64px;
  }

  .page-home .ph-hero-grid {
    grid-template-columns: 7fr 5fr;
    align-items: start;
    gap: 40px;
  }

  .page-home .ph-index-panel {
    margin: -56px 0 0 20px;
  }

  .page-home .ph-steps {
    padding: 64px 0 56px;
  }

  .page-home .ph-steps-list {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0;
  }

  .page-home .ph-step {
    padding: 24px 26px 8px 0;
    border-top: 2px solid var(--ink-600);
  }

  .page-home .ph-step + .ph-step {
    padding-left: 26px;
    border-left: 1px solid var(--ink-600);
  }

  .page-home .ph-board,
  .page-home .ph-devices,
  .page-home .ph-diag {
    padding: 64px 0;
  }

  .page-home .ph-bento {
    grid-template-columns: repeat(12, 1fr);
    gap: 18px;
  }

  .page-home .ph-cell--docs {
    grid-column: 1 / 8;
  }

  .page-home .ph-cell--version {
    grid-column: 8 / 13;
  }

  .page-home .ph-cell--search {
    grid-column: 1 / 6;
  }

  .page-home .ph-cell--adapter {
    grid-column: 6 / 13;
  }

  .page-home .ph-devices-wrap {
    grid-template-columns: 5fr 7fr;
    align-items: center;
    gap: 44px;
  }

  .page-home .ph-diag-grid {
    grid-template-columns: 5fr 7fr;
    gap: 46px;
    align-items: start;
  }

  .page-home .ph-updates-band img {
    height: 250px;
  }
}

@media (min-width: 1180px) {
  .page-home .ph-cell--docs {
    grid-column: 1 / 7;
  }

  .page-home .ph-cell--version {
    grid-column: 7 / 13;
  }

  .page-home .ph-cell--search {
    grid-column: 1 / 5;
  }

  .page-home .ph-cell--adapter {
    grid-column: 5 / 13;
  }
}

@media (prefers-reduced-motion: reduce) {
  .page-home .ph-update-item a,
  .page-home .ph-diag-item {
    transition: opacity var(--t-fast);
  }

  .page-home .ph-update-item a:hover,
  .page-home .ph-update-item a:focus-visible {
    transform: none;
  }
}
