.foerdergelder-bar {
  position: relative;
  width: 100%;
  height: 20px;
  background: var(--bar-color, #47a3a1);
  margin: 80px 0;
  transform: scaleX(0);
  transform-origin: left;
}

.foerdergelder-block.is-visible .foerdergelder-bar {
  animation: fundingGrow 1.2s ease-out forwards;
}

.foerdergelder-bar .bp {
  position: absolute;
  top: 0;
  left: var(--pos);
  transform: translateX(-50%);
  text-align: center;
  opacity: 0;
}

.foerdergelder-block.is-visible .bp {
  animation: fadeIn 0.4s ease-out forwards;
  animation-delay: 1.1s;
}

.bp-marker {
  display: block;
  width: 4px;
  height: 45px;
  background: var(--bar-color, #47a3a1);
  margin: -12px auto 0;
}

.bp-amount {
  position: absolute;
  top: -45px;
  left: 50%;
  transform: translateX(-50%);
  white-space: nowrap;
  color: #00000066;
}

.bp-year {
  position: absolute;
  top: 35px;
  left: 50%;
  transform: translateX(-50%);
  white-space: nowrap;
}

.bp-total {
  transform: translateX(-100%);
}

.bp-total .bp-amount {
  font-weight: 600;
  color: #000;
}

@keyframes fundingGrow {
  from {
    transform: scaleX(0);
  }
  to {
    transform: scaleX(1);
  }
}

@keyframes fadeIn {
  to {
    opacity: 1;
  }
}

@media (max-width: 768px) {
  .foerdergelder-bar {
    width: 4px;
    height: var(--mobile-height, 500px);
    margin: 40px 0 40px 30px;
    transform: scaleX(1) scaleY(0);
    transform-origin: top;
  }

  .foerdergelder-block.is-visible .foerdergelder-bar {
    animation: fundingGrowVertical 1.2s ease-out forwards;
  }

  @keyframes fundingGrowVertical {
    from {
      transform: scaleY(0);
    }
    to {
      transform: scaleY(1);
    }
  }

  .foerdergelder-bar .bp {
    left: 0 !important;
    top: var(--pos);
    transform: translateY(-50%);
    text-align: left;
    width: auto;
    white-space: nowrap;
  }

  .bp-marker {
    width: 20px;
    height: 3px;
    margin: 0;
  }

  .bp-amount {
    position: relative;
    left: 35px;
    top: 0;
    transform: none;
    display: block;
    line-height: 1.2;
    margin-bottom: 2px;
    color: #000;
  }

  .bp-year {
    position: relative;
    left: 35px;
    top: 0;
    transform: none;
    display: block;
    line-height: 1.2;
    color: #00000066;
  }

  .bp-total .bp-amount {
    font-weight: 700;
    color: #000;
  }
}
