/*
 * Progress indicator vertical
 *
 * Index
 * - Progress indicator Vertical
 * - Progress indicator item
 * - Progress indicator link
 * - Progress indicator icon
 * - Progress indicator title
 * - Step completed
 *
 */


/* PROGRESS INDICATOR VERTICAL
 -------------------- */

.progress-indicator-vertical {
  display: flex;
  flex-direction: column;
  padding-left: 0;
  list-style: none;
}

/* PROGRESS INDICATOR VERTICAL ITEM
   -------------------- */

.progress-indicator-vertical-item {
  display: flex;
  flex-direction: row;
  justify-content: flex-start;
  min-height: 65px;
}


.progress-indicator-vertical-item-content {
  display: inline-block;
  margin-left: 1rem;
}

/**
* Disabled click for current and next steps
*/

.progress-indicator-vertical-item:not(.completed) .progress-indicator-vertical-link {
  cursor: not-allowed;
}

/* VERTICAL STEPPER LINK
   -------------------- */

.progress-indicator-vertical-link {
  position: relative;
  z-index: 1;
  display: flex;
}

/* VERTICAL STEPPER ICON
   -------------------- */

.progress-indicator-vertical-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.5rem;
  height: 1.5rem;
  font-size: var(--road-font-size-12);
  font-weight: 700;
  color: var(--road-on-surface-disabled);
  background: var(--road-surface-disabled);
  border-radius: 50%;
  fill: currentColor;
}

.progress-indicator-vertical-line {
  position: absolute;
  top: 24px;
  left: 11px;
  z-index: -1;
  height: calc(100% - 24px);
  border-left: 2px solid var(--road-surface-disabled);
}

.progress-indicator-vertical-item:last-child .progress-indicator-vertical-line {
  border-left: 0;
}

/* VERTICAL STEPPER SUBSTEP ICON
   -------------------- */

.progress-indicator-vertical-substep-link {
  position: relative;
  z-index: 1;
  display: flex;
  margin: 0 0.5rem;
}

.progress-indicator-vertical-substep-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 0.5rem;
  height: 0.5rem;
  margin-top: 0.7rem;
  background: var(--road-surface-disabled);
  border-radius: 50%;
}

.progress-indicator-vertical-substep-beforeline {
  position: absolute;
  top: 0;
  left: 3px;
  z-index: -1;
  height: calc(30% - 8px);
  border-left: 2px solid var(--road-surface-disabled);
}

.progress-indicator-vertical-substep-line {
  position: absolute;
  top: 19px;
  left: 3px;
  z-index: -1;
  height: calc(83% - 8px);
  border-left: 2px solid var(--road-surface-disabled);
}

/* VERTICAL STEPPER TITLE
   -------------------- */

.progress-indicator-vertical-title {
  display: block;
  font-size: var(--road-body-large);
  font-weight: 700;
  color: var(--road-on-surface-disabled);
}

.progress-indicator-vertical-description{
  display: block;
  margin: 0;
  font-size: var(--road-label-small);
  font-weight: 400;
  color: var(--road-on-surface-disabled);
}

/* STEP CURRENT
   -------------------- */

.current .progress-indicator-vertical-icon {
  color: var(--road-on-primary);
  background: var(--road-primary);
  border: 0;
}

.current .progress-indicator-vertical-title {
  font-weight: 700;
  color: var(--road-on-surface);
}

.current .progress-indicator-vertical-description{
  color: var(--road-on-surface-weak);
}

.current .progress-indicator-vertical-substep-icon {
  background: var(--road-primary);
  border: 0;
}

.current .progress-indicator-vertical-substep-beforeline {
  border-left: 2px solid var(--road-primary);
}

/* STEP CURRENT
   -------------------- */

.in-progress .progress-indicator-vertical-icon {
  color: var(--road-on-primary);
  background: var(--road-primary);
  border: 0;
}

.in-progress .progress-indicator-vertical-title {
  font-weight: 700;
  color: var(--road-on-surface);
}

.in-progress .progress-indicator-vertical-description{
  color: var(--road-on-surface-weak);
}

.in-progress .progress-indicator-vertical-line {
  background: var(--road-primary);
}

/* STEP COMPLETED
   -------------------- */

.completed:not(:last-child)::after {
  background: var(--road-primary);
}

.completed .progress-indicator-vertical-icon {
  color: var(--road-primary);
  background: none;
  border: 2px solid var(--road-primary);
}

.completed .progress-indicator-vertical-line {
  border-left: 2px solid var(--road-primary);
}

.completed .progress-indicator-vertical-substep-beforeline {
  border-left: 2px solid var(--road-primary);
}

.completed .progress-indicator-vertical-substep-line {
  border-left: 2px solid var(--road-primary);
}

.completed .progress-indicator-vertical-title {
  font-weight: 700;
  color: var(--road-on-surface);
}

.completed .progress-indicator-vertical-description{
  color: var(--road-on-surface-weak);
}

.completed .progress-indicator-vertical-substep-icon {
  background: none;
  border: 2px solid var(--road-primary);
}
