/* The First steps card (js/components/setup-card.js): under Portfolio's four
   windows, one card with the steps as a row of rings - v13's checklist, our
   tokens. A copy that may not save shows the same card with the demo alone
   (.fs--demo). The first-run windows it replaced (fr-*) are gone. */

/* ---- The First steps card (stepsCardHtml; v13's card, our tokens) ---- */
.fs {
  position: relative; /* the screen-reader text of a done step is positioned: it must not grow the page */
  display: grid;
  grid-template-columns: 190px minmax(0, 1fr) auto;
  align-items: center;
  gap: 24px;
  padding: 16px 20px;
  border-radius: var(--r-window);
  background: var(--window);
  box-shadow: var(--window-edge);
}

.fs__h b {
  display: block;
  font-size: 15px;
  font-weight: 600;
  color: var(--text-1);
}

.fs__h > span {
  font-size: 13px;
  color: var(--text-2);
}

.fs__prog {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: 1fr;
  gap: 4px;
  width: 120px;
  margin-top: 8px;
}

.fs__prog i {
  height: 4px;
  border-radius: 2px;
  background: var(--track);
}

.fs__prog i.is-done {
  background: var(--lead);
}

.fs__list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 18px;
}

.fs__st {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  min-width: 0;
  padding: 0;
  border: 0;
  background: none;
  font: inherit;
  color: inherit;
  text-align: left;
}

button.fs__st {
  cursor: pointer;
}

button.fs__st:focus-visible,
.fs__hide:focus-visible {
  outline: 2px solid var(--lead);
  outline-offset: 3px;
  border-radius: 10px;
}

.fs__ck {
  flex: none;
  display: grid;
  place-items: center;
  width: 22px;
  height: 22px;
  margin-top: 1px;
  border-radius: 50%;
  box-shadow: inset 0 0 0 1.5px var(--text-3);
}

.fs__ck svg {
  width: 13px;
  height: 13px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.fs__st.is-done .fs__ck {
  background: var(--lead);
  box-shadow: none;
  color: var(--on-lead);
}

.fs__st b {
  display: block;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-1);
}

.fs__st.is-done b {
  font-weight: 500;
  color: var(--text-2);
}

.fs__sub {
  display: block;
  font-size: 13px;
  color: var(--text-2);
}

/* What an open step does, in the lead colour: the way in is named, not guessed. */
.fs__act {
  display: block;
  margin-top: 2px;
  font-size: 13px;
  font-weight: 600;
  color: var(--lead);
}

button.fs__st:hover .fs__act {
  text-decoration: underline;
  text-underline-offset: 3px;
}

.fs--demo {
  grid-template-columns: 190px minmax(0, 1fr);
}

.fs__hide {
  padding: 6px 10px;
  border: 0;
  border-radius: 9px;
  background: none;
  font: inherit;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-2);
  cursor: pointer;
}

.fs__hide:hover {
  background: var(--win-tile);
  color: var(--text-1);
}

@media (max-width: 980px) {
  .fs {
    grid-template-columns: minmax(0, 1fr) auto;
  }

  .fs__list {
    grid-column: 1 / -1;
    grid-row: 2;
  }
}

@media (max-width: 560px) {
  .fs,
  .fs--demo {
    grid-template-columns: minmax(0, 1fr);
    gap: 16px;
  }

  .fs__hide {
    justify-self: start;
    padding-left: 0;
  }
}

.pf-steps-slot:empty {
  display: none;
}

/* The first-entry panel (js/components/start-panel.js). */
.st-way {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
  padding: var(--space-3) 0;
  border-top: 1px solid var(--color-border);
}

.st-way__t {
  min-width: 0;
}

.st-way__t p {
  margin: var(--space-1) 0 0;
  color: var(--color-text-secondary);
  font-size: var(--fs-footnote);
}

.st-way .btn {
  flex: none;
}

.st-more {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
  padding-top: var(--space-3);
  border-top: 1px solid var(--color-border);
}

@media (max-width: 560px) {
  .st-way {
    flex-direction: column;
    align-items: flex-start;
  }
}
