/* =========================
Progress
Figma: Number Progress Indicator + linear progress bars.
========================= */
@use "../kit-deps" as *;
// Linear progress
.progress {
width: 100%;
max-width: 600px;
height: 8px;
border-radius: $radius-full;
background-color: $neutral-100;
overflow: hidden;
& + .progress {
margin-top: $space-5;
}
.progress-bar {
height: 100%;
border-radius: $radius-full;
background-color: $mint-600;
transition: width $motion-base $motion-ease;
}
// Variants
&.progress-primary .progress-bar { background-color: $neutral-900; }
&.progress-accent .progress-bar { background-color: $yellow-300; }
&.progress-success .progress-bar { background-color: $success-text; }
&.progress-warning .progress-bar { background-color: $warning-text; }
&.progress-danger .progress-bar { background-color: $danger-text; }
// Sizes
&.progress-sm { height: 4px; }
&.progress-lg { height: 12px; }
}
// Circular / step indicator
.progress-step {
display: inline-flex;
align-items: center;
justify-content: center;
flex-shrink: 0;
width: 32px;
height: 32px;
border-radius: $radius-full;
background-color: $neutral-0;
border: $border-width-base $border-style-base $neutral-300;
color: $neutral-500;
font-family: $font-family-base;
font-size: 13px;
font-weight: $font-weight-bold;
line-height: 1;
&.is-active {
background-color: $mint-600;
border-color: $mint-600;
color: $neutral-0;
}
&.is-complete {
background-color: $success-text;
border-color: $success-text;
color: $neutral-0;
}
&.is-accent {
background-color: $yellow-300;
border-color: $yellow-300;
color: $neutral-900;
}
// Sizes
&.progress-step-sm {
width: 24px;
height: 24px;
font-size: 11px;
}
&.progress-step-lg {
width: 48px;
height: 48px;
font-size: 18px;
}
}
// Staged progress
.progress-stages {
display: inline-flex;
align-items: center;
flex-wrap: wrap;
gap: $space-2;
font-size: 13px;
font-weight: $font-weight-semibold;
line-height: 1;
.progress-stage {
display: inline-flex;
align-items: center;
gap: $space-2;
padding: $space-2 $space-3;
border-radius: $radius-md;
background-color: $neutral-100;
color: $neutral-500;
transition: background-color $motion-base $motion-ease, color $motion-base $motion-ease;
&::before {
content: "";
width: 8px;
height: 8px;
border-radius: $radius-full;
background-color: currentColor;
opacity: 0.5;
}
&.progress-stage-complete {
background-color: rgba($success-text, 0.12);
color: $success-text;
&::before {
opacity: 1;
}
}
&.progress-stage-current {
background-color: rgba($mint-600, 0.12);
color: $mint-700;
&::before {
opacity: 1;
box-shadow: 0 0 0 3px rgba($mint-600, 0.2);
}
}
}
}
/* Usage meter */
.usage-meter {
width: 100%;
max-width: 600px;
.usage-meter-title {
display: flex;
align-items: center;
justify-content: space-between;
gap: $space-3;
margin: 0 0 $space-3;
font-size: $font-size-lg;
font-weight: $font-weight-bold;
color: $neutral-900;
}
.usage-meter-value {
font-size: $font-size-base;
font-weight: $font-weight-semibold;
color: $neutral-500;
}
.usage-meter-meta {
margin: $space-2 0 0;
color: $neutral-500;
font-size: $font-size-sm;
}
}