.voice-flow {
  --flow-progress: 1;
  --flow-crossfade: 1;
  margin: -10px 0 66px;
  overflow: hidden;
  color: var(--ink);
}
.flow-stage {
  position: relative;
  height: 260px;
  overflow: hidden;
  contain: layout paint;
}
.flow-svg {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  overflow: visible;
  font-family: var(--font);
  font-size: 22px;
  font-weight: 500;
}
.flow-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}
.flow-text-ready .flow-raw,
.flow-text-ready .flow-clean,
.flow-text-ready #voice-bars {
  visibility: hidden;
}
.flow-raw {
  fill: #afaaa4;
}
.flow-band {
  fill: none;
  stroke: #f1e5e0;
  stroke-width: 43px;
}
.flow-clean {
  fill: #432d3d;
}
.flow-clean .flow-name {
  fill: #9e493a;
}
.flow-capsule {
  fill: #201426;
  stroke: #37233f;
  stroke-width: 1px;
}
#voice-bars {
  fill: #c9a8e8;
}
#voice-bars rect:nth-child(-n + 4) {
  fill: #f08a7a;
}
#voice-bars rect:nth-child(n + 10) {
  fill: #7fb2e8;
}
.flow-caption {
  text-align: center;
}
.flow-edit {
  display: grid;
  align-items: center;
  min-height: 45px;
  font-size: clamp(17px, 1.65vw, 22px);
  line-height: 1.8;
}
.flow-edit p {
  grid-area: 1 / 1;
  margin: 0;
}
.flow-edit-original {
  opacity: calc(1 - var(--flow-crossfade));
  transform: translateY(calc(var(--flow-crossfade) * -7px));
  color: var(--ink-secondary);
}
.flow-discard {
  color: #a39993;
  background: linear-gradient(#b27e6a, #b27e6a) left 55% /
    calc(var(--flow-progress) * 100%) 1px no-repeat;
  opacity: calc(1 - var(--flow-crossfade));
}
.flow-edit-result {
  opacity: var(--flow-crossfade);
  transform: translateY(calc((1 - var(--flow-crossfade)) * 7px));
  font-weight: 500;
}
.flow-edit-result > span {
  color: var(--coral);
}
.flow-assistant {
  position: absolute;
  top: 32px;
  left: 50%;
  z-index: 1;
  width: min(320px, calc(100% - 32px));
  transform: translateX(-50%);
  text-align: center;
  pointer-events: none;
}
.flow-assist-steps {
  display: grid;
  align-items: center;
  min-height: 43px;
  margin-top: 3px;
  color: #432d3d;
  font-size: 19px;
  font-weight: 500;
}
.flow-assist-step {
  grid-area: 1 / 1;
  opacity: 0;
}
.flow-assist-step:first-child {
  opacity: 1;
}
[data-running] .flow-assist-step {
  animation: flow-assist 12s linear infinite both paused;
}
[data-running] .flow-assist-step:nth-child(2) {
  animation-delay: 3s;
}
[data-running] .flow-assist-step:nth-child(3) {
  animation-delay: 6s;
}
[data-running] .flow-assist-step:nth-child(4) {
  animation-delay: 9s;
}
[data-running="true"] .flow-assist-step {
  animation-play-state: running;
}
.flow-assist-stem {
  display: block;
  width: 1px;
  height: 20px;
  margin: 7px auto 0;
  background: linear-gradient(#d5b8c6, #d5b8c600);
}
@keyframes flow-assist {
  0% {
    opacity: 0;
    transform: translateY(9px);
  }
  4% {
    opacity: 1;
    transform: translateY(0);
  }
  20% {
    opacity: 1;
    transform: translateY(-3px);
  }
  25%,
  100% {
    opacity: 0;
    transform: translateY(-12px);
  }
}
.flow-sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}
@media (max-width: 720px) {
  .voice-flow {
    margin-top: -15px;
    margin-bottom: 37px;
  }
  .flow-stage {
    height: 224px;
  }
  .flow-svg {
    font-size: 18px;
  }
  .flow-band {
    stroke-width: 37px;
  }
  .flow-assistant {
    top: 27px;
  }
  .flow-assist-steps {
    font-size: 17px;
    min-height: 38px;
  }
  .flow-assist-stem {
    height: 14px;
    margin-top: 3px;
  }
  .flow-edit {
    min-height: 88px;
    line-height: 1.85;
  }
}
@media (prefers-reduced-motion: reduce) {
  .voice-flow {
    --flow-progress: 1 !important;
    --flow-crossfade: 1 !important;
  }
  .voice-flow .flow-assist-step {
    animation: none;
    opacity: 0;
    transform: none;
  }
  .voice-flow .flow-assist-step:last-child {
    opacity: 1;
  }
}
