/* UX F1: wizard step bar (WizardStepBar in FrancophoneGamesV2.UI.Shared), ported from RAMPAppPrj's scheduler-board.css
   (.sb-steps rules only, including the RU-30 compact-width fix). Linked by the Admin, Volunteer and Participant apps as
   _content/FrancophoneGamesV2.UI.Shared/css/wizard.css. */
.sb-steps {
    display: flex;
    gap: 6px;
    overflow-x: auto;
    padding-bottom: 2px;
}

/* Inside a dialog: steps wrap onto more rows instead of scrolling, each as wide as its title needs (capped), with long
   titles wrapping between words and the status clipped, so nothing spills into the next step. */
.sb-steps-compact {
    flex-wrap: wrap;
}

.sb-steps-compact .sb-step {
    flex: 1 1 auto;
    min-width: min-content;
    max-width: 240px;
    padding: 6px 8px;
}

.sb-steps-compact .sb-step-text {
    flex: 1 1 auto;
    overflow: visible;
    min-width: min-content;
}

.sb-steps-compact .sb-step-title {
    white-space: normal;
    overflow-wrap: break-word;
    line-height: 1.2;
}

/* The status is clipped to the step's width and must not count towards the step's minimum width. */
.sb-steps-compact .sb-step-status {
    width: 0;
    min-width: 100%;
}

.sb-step {
    flex: 1 1 0;
    min-width: 140px;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 10px;
    border: 1px solid var(--mud-palette-lines-default);
    border-radius: 6px;
    background: var(--mud-palette-surface);
    color: var(--mud-palette-text-primary);
    text-align: left;
    cursor: pointer;
    font: inherit;
}

.sb-step:disabled {
    cursor: not-allowed;
    opacity: 0.55;
}

.sb-step:focus-visible {
    outline: 2px solid var(--mud-palette-primary);
    outline-offset: 2px;
}

.sb-step-active {
    border: 2px solid var(--mud-palette-primary);
    background: rgba(var(--mud-palette-primary-rgb), 0.08);
}

.sb-step-marker {
    flex: 0 0 26px;
    height: 26px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    background: var(--mud-palette-background-gray);
}

.sb-step-done .sb-step-marker {
    color: var(--mud-palette-success);
}

.sb-step-attention .sb-step-marker {
    color: var(--mud-palette-warning);
}

.sb-step-text {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.sb-step-title {
    font-weight: 600;
    white-space: nowrap;
}

.sb-step-status {
    font-size: 0.75rem;
    color: var(--mud-palette-text-secondary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
