.page-products {
  --pw-cut: 18px;
  --pw-hot: #E7F1FB;
  padding-top: clamp(16px, 3vw, 32px);
  padding-bottom: clamp(48px, 8vw, 96px);
  color: var(--ink);
  font-family: var(--font-body);
}

.page-products__crumb {
  margin-bottom: clamp(18px, 3vw, 28px);
}

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

/* ---------- 首屏工作台 ---------- */
.tool-hero {
  max-width: 840px;
  margin: 0 0 clamp(40px, 6vw, 72px);
  padding-left: clamp(16px, 3vw, 26px);
  border-left: 3px solid var(--blue);
}

.tool-hero__kicker {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 18px;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: .16em;
  color: var(--blue);
}

.tool-hero__mark {
  width: 18px;
  height: 4px;
  background: var(--red);
}

.tool-hero__title {
  margin: 0 0 20px;
  font-family: var(--font-display);
  font-weight: 900;
  font-size: clamp(30px, 6vw, 56px);
  line-height: 1.14;
  letter-spacing: -.02em;
  color: var(--deep);
}

.tool-hero__lede {
  margin: 0;
  font-size: clamp(16px, 2vw, 18px);
  line-height: 1.85;
  color: var(--ink);
}

.tool-hero__stats {
  display: grid;
  grid-template-columns: 1fr;
  gap: 18px;
  margin-top: 28px;
  padding-top: 24px;
  border-top: 1px solid var(--mist);
}

.tool-stat {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.tool-stat__num {
  font-family: var(--font-mono);
  font-size: clamp(22px, 3.6vw, 30px);
  font-weight: 700;
  letter-spacing: -.01em;
  color: var(--blue);
}

.tool-stat__label {
  font-size: 13px;
  line-height: 1.5;
  color: var(--ink);
  opacity: .72;
}

@media (min-width: 640px) {
  .tool-hero__stats {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* ---------- 工具卡 ---------- */
.toolwork {
  margin-bottom: clamp(48px, 8vw, 88px);
}

.toolwork__intro {
  max-width: 620px;
  margin: 0 0 26px;
  font-size: 16px;
  line-height: 1.8;
  color: var(--ink);
}

.toolwork__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.toolcard {
  display: flex;
  flex-direction: column;
  padding: 22px 20px 20px;
  background: var(--paper);
  box-shadow: inset 0 0 0 1px var(--mist);
  clip-path: polygon(0 0, calc(100% - var(--pw-cut)) 0, 100% var(--pw-cut), 100% 100%, 0 100%);
  transition: transform .24s var(--ease), filter .24s var(--ease);
}

.toolcard:hover,
.toolcard:focus-within {
  transform: translateY(-4px);
  filter: drop-shadow(0 14px 16px rgba(8, 59, 111, .16));
}

.toolcard__no {
  margin-bottom: 10px;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: .12em;
  color: var(--red);
}

.toolcard__title {
  margin: 0 0 10px;
  font-family: var(--font-display);
  font-size: 21px;
  font-weight: 800;
  line-height: 1.3;
  color: var(--deep);
}

.toolcard__text {
  margin: 0 0 16px;
  font-size: 15px;
  line-height: 1.8;
  color: var(--ink);
}

.toolcard__tag {
  align-self: flex-start;
  margin-bottom: 14px;
}

.toolcard__link {
  align-self: flex-start;
  margin-top: auto;
  padding-bottom: 2px;
  font-size: 14px;
  font-weight: 700;
  color: var(--blue);
  text-decoration: none;
  border-bottom: 2px solid var(--yellow);
  transition: color .2s var(--ease);
}

.toolcard__link:hover {
  color: var(--red);
}

.toolcard__link:focus-visible {
  outline: 2px solid var(--yellow);
  outline-offset: 3px;
}

@media (min-width: 640px) {
  .toolwork__grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1024px) {
  .toolwork__grid {
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
  }

  .toolcard:nth-child(even) {
    margin-top: 32px;
  }
}

/* ---------- 检索详解 ---------- */
.searchmap {
  padding: clamp(22px, 4vw, 44px);
  margin-bottom: clamp(48px, 8vw, 88px);
  background: var(--paper);
  box-shadow: inset 0 0 0 1px var(--mist);
  clip-path: polygon(0 0, 100% 0, 100% calc(100% - 26px), calc(100% - 26px) 100%, 0 100%);
}

.searchmap__figure {
  margin: 0 0 26px;
}

.searchmap__img {
  display: block;
  width: 100%;
  max-width: 100%;
  height: auto;
  object-fit: cover;
}

.searchmap__caption {
  margin-top: 12px;
  font-size: 13px;
  line-height: 1.6;
  color: var(--ink);
  opacity: .7;
}

.searchmap__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.matchcard {
  --mc: var(--blue);
  padding: 18px 16px 20px;
  background: var(--snow);
  border-top: 4px solid var(--mc);
}

.matchcard:nth-child(1) { --mc: var(--yellow); }
.matchcard:nth-child(2) { --mc: var(--blue); }
.matchcard:nth-child(3) { --mc: var(--red); }
.matchcard:nth-child(4) { --mc: var(--green); }

.matchcard__index {
  display: inline-block;
  margin-bottom: 12px;
  padding: 3px 9px;
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .08em;
  color: var(--paper);
  background: var(--mc);
}

.matchcard:nth-child(1) .matchcard__index {
  color: var(--deep);
}

.matchcard__title {
  margin: 0 0 8px;
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 700;
  line-height: 1.4;
  color: var(--deep);
}

.matchcard__text {
  margin: 0;
  font-size: 14px;
  line-height: 1.75;
  color: var(--ink);
}

.searchmap__tip {
  margin: 26px 0 0;
  padding: 16px 18px;
  font-size: 15px;
  line-height: 1.8;
  color: var(--ink);
  background: var(--snow);
  border-left: 4px solid var(--yellow);
}

@media (min-width: 560px) {
  .searchmap__grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1024px) {
  .searchmap__grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

/* ---------- 版本号 ---------- */
.versions {
  margin-bottom: clamp(48px, 8vw, 88px);
}

.versions__lede {
  max-width: 700px;
  margin: 0 0 34px;
  font-size: 16px;
  line-height: 1.85;
  color: var(--ink);
}

.versions__sub {
  margin: 0 0 18px;
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -.01em;
  color: var(--blue);
}

.versions__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
  margin-bottom: clamp(36px, 6vw, 60px);
}

.wherecard {
  padding: 22px 20px;
  background: var(--paper);
  box-shadow: inset 0 0 0 1px var(--mist);
}

.wherecard__label {
  display: inline-block;
  margin-bottom: 12px;
  padding: 3px 8px;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: .14em;
  color: var(--snow);
  background: var(--deep);
}

.wherecard__name {
  margin: 0 0 8px;
  font-size: 17px;
  font-weight: 700;
  line-height: 1.5;
  color: var(--deep);
}

.wherecard__text {
  margin: 0;
  font-size: 15px;
  line-height: 1.78;
  color: var(--ink);
}

.versiontable__figure {
  margin: 0 0 26px;
}

.versiontable__img {
  display: block;
  width: 100%;
  max-width: 100%;
  height: auto;
}

.versiontable__wrap {
  max-width: 940px;
  overflow-x: auto;
}

.versiontable__table {
  width: 100%;
  min-width: 620px;
  border-collapse: collapse;
  font-size: 15px;
}

.versiontable__table th,
.versiontable__table td {
  padding: 18px 16px;
  text-align: left;
  vertical-align: top;
  line-height: 1.72;
  border-bottom: 1px solid var(--mist);
}

.versiontable__table thead th {
  padding: 0 16px 12px;
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .12em;
  color: var(--deep);
  border-bottom: 2px solid var(--blue);
  white-space: nowrap;
}

.versiontable__table tbody tr {
  transition: background .2s var(--ease), box-shadow .2s var(--ease);
}

.versiontable__table tbody tr:nth-child(even) {
  background: var(--snow);
}

.versiontable__table tbody tr:hover {
  background: var(--pw-hot);
  box-shadow: inset 3px 0 0 var(--blue);
}

.versiontable__code {
  font-family: var(--font-mono);
  font-size: 16px;
  font-weight: 700;
  color: var(--red);
  white-space: nowrap;
}

.versiontable__table tr.is-current .versiontable__code {
  color: var(--green);
}

.versions__note {
  max-width: 720px;
  margin: 22px 0 0;
  font-size: 14px;
  line-height: 1.8;
  color: var(--ink);
  opacity: .78;
}

@media (min-width: 768px) {
  .versions__grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* ---------- 四步上手 ---------- */
.steps {
  margin-bottom: clamp(48px, 8vw, 88px);
}

.steps__lede {
  max-width: 660px;
  margin: 0 0 30px;
  font-size: 16px;
  line-height: 1.85;
  color: var(--ink);
}

.steps__layout {
  display: grid;
  grid-template-columns: 1fr;
  gap: 28px;
}

.steps__figure {
  margin: 0;
}

.steps__img {
  display: block;
  width: 100%;
  max-width: 100%;
  height: auto;
}

.steps__list {
  position: relative;
  margin: 0;
  padding: 0 0 0 32px;
  list-style: none;
}

.steps__list::before {
  content: "";
  position: absolute;
  left: 9px;
  top: 20px;
  bottom: 20px;
  width: 2px;
  background: repeating-linear-gradient(to bottom, var(--sky) 0 9px, transparent 9px 17px);
}

.step {
  position: relative;
  margin-bottom: 14px;
}

.step:last-child {
  margin-bottom: 0;
}

.step::before {
  content: "";
  position: absolute;
  left: -29px;
  top: 18px;
  width: 14px;
  height: 14px;
  box-sizing: border-box;
  border-radius: 50%;
  background: var(--snow);
  border: 3px solid var(--blue);
}

.step__box {
  background: var(--paper);
  box-shadow: inset 0 0 0 1px var(--mist);
  transition: box-shadow .2s var(--ease);
}

.step__box[open] {
  box-shadow: inset 0 0 0 2px var(--sky);
}

.step__summary {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 15px 18px;
  cursor: pointer;
  list-style: none;
  font-family: var(--font-display);
  font-size: 17px;
  font-weight: 700;
  color: var(--deep);
}

.step__summary::-webkit-details-marker {
  display: none;
}

.step__summary::after {
  content: "+";
  margin-left: auto;
  font-family: var(--font-mono);
  font-size: 18px;
  color: var(--sky);
}

.step__box[open] .step__summary::after {
  content: "−";
}

.step__summary:focus-visible {
  outline: 2px solid var(--yellow);
  outline-offset: -2px;
}

.step__no {
  font-family: var(--font-mono);
  font-size: 20px;
  font-weight: 700;
  letter-spacing: -.02em;
  color: var(--red);
}

.step__name {
  flex: 1 1 auto;
}

.step__body {
  padding: 0 18px 18px;
}

.step__body p {
  margin: 0;
  font-size: 15px;
  line-height: 1.85;
  color: var(--ink);
}

@media (min-width: 900px) {
  .steps__layout {
    grid-template-columns: .85fr 1.15fr;
    gap: 40px;
    align-items: start;
  }
}

/* ---------- 兼容 ---------- */
.compat {
  margin-bottom: clamp(48px, 8vw, 88px);
}

.compat__layout {
  display: grid;
  grid-template-columns: 1fr;
  gap: 26px;
  align-items: start;
}

.compat__lede {
  margin: 0 0 22px;
  font-size: 16px;
  line-height: 1.85;
  color: var(--ink);
}

.compat__tablewrap {
  overflow-x: auto;
}

.compat__table {
  width: 100%;
  min-width: 480px;
  border-collapse: collapse;
  font-size: 14px;
}

.compat__table th,
.compat__table td {
  padding: 14px 10px;
  text-align: left;
  line-height: 1.6;
  border-bottom: 1px solid var(--mist);
}

.compat__table thead th {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: .1em;
  color: var(--deep);
  border-bottom: 2px solid var(--blue);
  white-space: nowrap;
}

.compat__table tbody th {
  font-weight: 700;
  color: var(--deep);
  white-space: nowrap;
}

.compat__browsers {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 24px 0 0;
  padding: 0;
  list-style: none;
}

.compat__browsers li {
  padding: 5px 12px;
  font-family: var(--font-mono);
  font-size: 13px;
  color: var(--deep);
  background: var(--paper);
  box-shadow: inset 0 0 0 1px var(--mist);
}

.compat__figure {
  margin: 0;
}

.compat__img {
  display: block;
  width: 100%;
  max-width: 100%;
  height: auto;
}

.compat__caption {
  margin-top: 12px;
  font-size: 13px;
  line-height: 1.6;
  color: var(--ink);
  opacity: .7;
}

@media (min-width: 900px) {
  .compat__layout {
    grid-template-columns: 1.05fr .95fr;
    gap: 40px;
  }
}

/* ---------- 场景选择 ---------- */
.scenario {
  margin-bottom: 0;
}

.scenario__figure {
  max-width: 560px;
  margin: 0 0 30px;
}

.scenario__img {
  display: block;
  width: 100%;
  max-width: 100%;
  height: auto;
}

.scenario__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}

.scenario__card {
  display: flex;
  flex-direction: column;
  padding: 22px 20px;
  background: var(--paper);
  box-shadow: inset 0 0 0 1px var(--mist);
  border-bottom: 4px solid var(--blue);
}

.scenario__card:nth-child(2) {
  border-bottom-color: var(--red);
}

.scenario__card:nth-child(3) {
  border-bottom-color: var(--green);
}

.scenario__tag {
  align-self: flex-start;
  margin-bottom: 14px;
}

.scenario__name {
  margin: 0 0 14px;
  font-family: var(--font-display);
  font-size: 19px;
  font-weight: 800;
  line-height: 1.4;
  color: var(--deep);
}

.scenario__path {
  counter-reset: sp;
  margin: 0 0 20px;
  padding: 0;
  list-style: none;
}

.scenario__path li {
  position: relative;
  padding-left: 28px;
  margin-bottom: 9px;
  font-size: 14px;
  line-height: 1.72;
  color: var(--ink);
}

.scenario__path li::before {
  counter-increment: sp;
  content: counter(sp, decimal-leading-zero);
  position: absolute;
  left: 0;
  top: 1px;
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 700;
  color: var(--sky);
}

.scenario__card .btn {
  align-self: flex-start;
  margin-top: auto;
}

@media (min-width: 768px) {
  .scenario__grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 18px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .toolcard,
  .toolcard__link,
  .step__box,
  .versiontable__table tbody tr {
    transition: none;
  }

  .toolcard:hover,
  .toolcard:focus-within {
    transform: none;
  }
}
