.pw-stepper {
  display: flex;
  align-items: flex-start;
  gap: var(--pw-space-1);
  list-style: none;
  padding: 0;
  margin: 0 0 var(--pw-space-7) 0;
  counter-reset: step;
}

.pw-stepper__step {
  display: flex;
  flex-direction: column;
  align-items: center;
  flex: 1;
  position: relative;
  text-align: center;
}

/* Connecting line between steps. `top: 14px` centers the line on the
   28px indicator's vertical midpoint — keep these in sync if the
   indicator size changes. */
.pw-stepper__step + .pw-stepper__step::before {
  content: "";
  position: absolute;
  top: 14px;
  right: 50%;
  width: 100%;
  height: 2px;
  background: var(--pw-color-border);   /* shares border on purpose: the connector is a hairline */
}

.pw-stepper__step--complete + .pw-stepper__step::before {
  background: var(--pw-color-status-success-fg);   /* shares success on purpose: completion is success */
}

.pw-stepper__indicator {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: var(--pw-radius-full);
  font-size: var(--pw-text-sm);
  font-weight: var(--pw-weight-semibold);
  position: relative;
  z-index: 1;
}

/* Upcoming: dimmed circle */
.pw-stepper__step--upcoming .pw-stepper__indicator {
  background: var(--pw-color-surface-sunken);
  color: var(--pw-color-text-muted);
  border: 2px solid var(--pw-color-border);
}

/* Current: filled circle plus a poppy accent halo ring, so it reads as the
   most emphatic step and differs from complete steps by shape. The ring is
   decorative emphasis, not error: the circle stays teal (PWP-220). The gap
   layer is surface-base because the wizard and /a/brand both sit on it; a
   stepper placed in a card needs that card's surface here instead. The gap
   also cuts the connector line cleanly. box-shadow is dropped in forced-colors
   mode, so the transparent outline stands in there as a system-colored ring. */
.pw-stepper__step--current .pw-stepper__indicator {
  background: var(--pw-color-accent-fill);
  color: var(--pw-color-accent-fill-text);
  box-shadow:
    0 0 0 2px var(--pw-color-surface-base),
    0 0 0 4px var(--pw-color-accent-ring);
  outline: 2px solid transparent;
  outline-offset: 2px;
}

/* Complete: success circle */
.pw-stepper__step--complete .pw-stepper__indicator {
  background: var(--pw-color-status-success-fg);   /* shares success on purpose: completion is success */
  color: var(--pw-color-text-on-fill);
}

.pw-stepper__check {
  font-size: var(--pw-text-xs);
  line-height: 1;
}

.pw-stepper__number {
  line-height: 1;
}

.pw-stepper__label {
  display: block;
  margin-top: var(--pw-space-1);
  font-size: var(--pw-text-xs);
  color: var(--pw-color-text-muted);
  line-height: var(--pw-leading-tight);
}

.pw-stepper__step--current .pw-stepper__label {
  color: var(--pw-color-text);
  font-weight: var(--pw-weight-medium);
}

/* Mobile: hide labels, show only indicators */
@media (max-width: 480px) {
  .pw-stepper__label {
    display: none;
  }
}
