/* Platform page (/platform, the v2 design): what differs from platform.css. */

/* ---------- The four ways in over the layer cake ---------- */
.pf2-model .pf-orch { position: relative; }
.pf2-model .pdiagram { margin-top: 0; }
.pf2-model { padding-bottom: 96px; }
/* the diagram's section style caps it at 1440px without centering it; here
   the section runs full width and its container centers, as elsewhere */
.pf2-model.compare-section--sandbox { max-width: none; }
/* centered on the page: an empty column on the right mirrors the stage
   labels on the left, so the band, and the four ways in over it, sit in the
   middle (rail = the labels' column, inset = grid padding + rail + gap).
   From 1200: narrower, the mirrored column leaves the four boxes too tight */
@media (min-width: 1200px) {
  .pf2-model { --pd-rail: 132px; --pd-inset: calc(14px + var(--pd-rail) + 32px); }
  .pf2-model .pd-grid { grid-template-columns: var(--pd-rail) minmax(0, 1fr) var(--pd-rail); }
  .pf2-model .pf-ways, .pf2-model .pf-wires { margin-left: var(--pd-inset); margin-right: var(--pd-inset); }
  .pf2-model .pf-wires { width: calc(100% - 2 * var(--pd-inset)); }
}

/* ---------- Steps: a label, the full cards, then the smaller features ----------
   Every step uses the same column grid (1 / 2 / 3 / 4 across, by width), so
   cards are one width across the section. The step's other features follow
   as text in the columns left over on the cards' last row (--span), set in
   as many text columns; when the cards fill the row they take a full row. */
.pf2-step { --cols: 1; --g: 20px; --span: 1; margin-top: 36px; }
.pf2-step-label {
  margin: 0 0 16px;
  padding-top: 12px;
  border-top: 1px solid var(--kit-teal-medium);
  color: var(--pf-ink);
}
.pf2-step-grid {
  display: grid;
  grid-template-columns: repeat(var(--cols), minmax(0, 1fr));
  gap: var(--g);
  margin: 0;
  padding: 0;
  list-style: none;
}
.pf2-step-card { display: flex; min-width: 0; }
.pf2-step-card .pf2-card { flex: 1; scroll-margin-top: 96px; }
/* the phase header needs no rule of its own here */
.pf2-feat .pf-fphase-head { padding-bottom: 0; border-bottom: 0; }

@media (min-width: 600px) {
  .pf2-step { --g: 24px; }
  .pf2-step-grid { max-width: 480px; }
}
@media (min-width: 768px) {
  .pf2-step { --cols: 2; }
  .pf2-step-grid { max-width: none; }
  .pf2-step[data-n="1"], .pf2-step[data-n="3"] { --span: 1; }
  .pf2-step[data-n="2"], .pf2-step[data-n="4"] { --span: 2; }
}
@media (min-width: 1024px) {
  .pf2-step { --cols: 3; --g: 28px; margin-top: 44px; }
  .pf2-step[data-n="1"], .pf2-step[data-n="4"] { --span: 2; }
  .pf2-step[data-n="2"] { --span: 1; }
  .pf2-step[data-n="3"] { --span: 3; }
  .pf2-feat .pf-fphase { margin-top: 112px; }
  .pf2-feat .pf-fphase:first-of-type { margin-top: 64px; }
}
@media (min-width: 1440px) {
  .pf2-step { --cols: 4; --g: 24px; }
  .pf2-step[data-n="4"] { --span: 4; }
  .pf2-step[data-n="1"] { --span: 3; }
  .pf2-step[data-n="2"] { --span: 2; }
  .pf2-step[data-n="3"] { --span: 1; }
}

/* ---------- The step's smaller features, as text ---------- */
.pf2-list { grid-column: span var(--span); align-self: start; min-width: 0; }
.pf2-list > ul {
  column-count: var(--span);
  column-gap: var(--g);
  margin: 0;
  padding: 0;
  list-style: none;
}
.pf2-list li { break-inside: avoid; }
.pf2-list-item {
  display: grid;
  gap: 2px;
  box-sizing: border-box;
  width: calc(100% + 20px);
  margin: 0 -10px;
  padding: 10px;
  border: 0;
  border-radius: 10px;
  background: none;
  font: inherit;
  text-align: left;
  cursor: pointer;
}
.pf2-list-name {
  font-size: var(--type-small);
  line-height: var(--type-body-lh);
  font-weight: var(--type-subhead-weight);
  color: var(--pf-ink);
}
.pf2-list-name .pf-ai { width: 14px; height: 14px; margin-right: 6px; vertical-align: -2px; color: var(--kit-teal-medium); }
.pf2-list-go { width: 14px; height: 14px; margin-left: 6px; vertical-align: -2px; color: var(--kit-teal-medium); opacity: 0; transition: opacity .15s ease, transform .15s ease; }
.pf2-list-line { font-size: var(--type-small); line-height: var(--type-body-lh); color: var(--pf-muted); }
.pf2-list-item:hover { background: var(--kit-white); }
.pf2-list-item:hover .pf2-list-go, .pf2-list-item:focus-visible .pf2-list-go { opacity: 1; transform: translateX(2px); }
.pf2-list-item:focus-visible { outline: 2px solid var(--kit-teal-medium); outline-offset: -2px; }
/* beside the cards the list starts level with their text */
@media (min-width: 768px) { .pf2-list { padding-top: 14px; } }
@media (prefers-reduced-motion: reduce) { .pf2-list-go { transition: none; } }

/* ---------- A feature's full card, opened over the page ---------- */
.pf2-dialog {
  width: min(420px, calc(100vw - 32px));
  max-height: calc(100dvh - 32px);
  margin: auto;
  padding: 0;
  border: 0;
  border-radius: 20px;
  background: transparent;
  overflow: auto;
}
.pf2-dialog::backdrop { background: rgba(13, 40, 40, .45); }
.pf2-dialog .pf2-card { position: relative; box-shadow: 0 24px 60px rgba(13, 40, 40, .25); }
.pf2-dialog-step { margin: 0 40px -8px 0; color: var(--pf-muted); }
.pf2-dialog-close {
  position: absolute;
  top: 16px;
  right: 16px;
  z-index: 1;
  width: 32px;
  height: 32px;
  border: 0;
  border-radius: 50%;
  background: var(--kit-white);
  box-shadow: 0 0 0 1px var(--kit-ivory-medium);
  cursor: pointer;
}
.pf2-dialog-close::before, .pf2-dialog-close::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 12px;
  height: 1.5px;
  margin: -.75px 0 0 -6px;
  background: var(--pf-ink);
  transform: rotate(45deg);
}
.pf2-dialog-close::after { transform: rotate(-45deg); }
.pf2-dialog-close:hover { box-shadow: 0 0 0 1px var(--kit-teal-medium); }
.pf2-dialog-close:focus-visible { outline: 2px solid var(--kit-teal-medium); outline-offset: 2px; }

/* ---------- Card foot: the ways in, then the card's logos ---------- */
.pf2-foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 16px;          /* 16px from the last label, as between labels */
  margin-top: auto;
}
.pf2-foot .pf-fcard-ways { margin: 0; }
/* the logos move as one group when the foot wraps, and never split */
.pf2-logos { flex-wrap: nowrap; gap: 8px; align-items: center; }
.pf2-logos .pf-logo { display: block; line-height: 0; }
.pf .pf2-logos .pf-logo .logo-tile { --tile: 26px; }
/* the logos sit on their own line under the labels; every card in a row
   keeps that line, logos or not, so labels and logos line up across it */
.pf2-logos { flex-basis: 100%; }
.pf2-step-grid .pf2-foot { display: grid; grid-template-rows: auto 26px; row-gap: 12px; }
