fieldset#add_cash-fieldset legend {
  color: black !important;
}

.container {
  position: relative;
  overflow: hidden;
  /* Prevents horizontal scrolling */
  min-height: 80px;
  /* Ensures a consistent height for smoother animation */

}

/* ✅ Ensure animations work */
#form-container {
  position: relative;
  overflow: hidden;
  min-height: 100px;
  /* Ensures content doesn't "jump" */
}

/* ✅ Transition effects */
.transition-content {
  opacity: 0;
  transform: translateX(100%);
  transition: opacity 0.4s ease-in-out, transform 0.4s ease-in-out;
}

/* ✅ Slide IN effect for new content */
.htmx-settling .transition-content {
  opacity: 1;
  transform: translateX(0);
}

/* ✅ Slide OUT effect for old content */
.htmx-swapping .transition-content {
  opacity: 0;
  transform: translateX(-100%);
}

/* ✅ Each step should take full width */
.step {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 80px;
}

.black-text {
  color: black !important;
}

@keyframes fade-in {
  from {
    opacity: 0;
  }
}

@keyframes fade-out {
  to {
    opacity: 0;
  }
}

@keyframes slide-from-right {
  from {
    transform: translateX(90px);
  }
}

@keyframes slide-to-left {
  to {
    transform: translateX(-90px);
  }
}


/* ✅ Apply View Transition API */
.slide-it {
  view-transition-name: slide-it;
}

::view-transition-old(slide-it) {
  animation: 180ms cubic-bezier(0.4, 0, 1, 1) both fade-out,
    600ms cubic-bezier(0.4, 0, 0.2, 1) both slide-to-left;
}

::view-transition-new(slide-it) {
  animation: 420ms cubic-bezier(0, 0, 0.2, 1) 90ms both fade-in,
    600ms cubic-bezier(0.4, 0, 0.2, 1) both slide-from-right;
}