.modal-wrapper {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  overflow: auto;
  opacity: 1;
  transition: opacity 0.25s;

  .modal-wrapper-inner {
    top: 0;
    position: absolute;
    display: flex;
    flex-direction: column;
    min-height: 100%;
    justify-content: center;
    align-items: center;
  }

  &.hidden {
    opacity: 0;
    pointer-events: none;
  }

  &.visible:first-child, :not(.visible) + &.visible {
    background-color: fade-out(#161616, 0.4);
  }

  background-color: fade-out(#161616, 0.4);
}
