.md-typeset mark {
  background-color: unset;
}

mark {
  --color1: var(--md-typeset-mark-color, rgba(255, 255, 0, 0.611));
  --color2: var(--md-typeset-mark-color, yellow);
  --bg-height: 60%;
    
  all: unset;
  background-image: linear-gradient(var(--color1), var(--color2));
  background-position: 0 100%;
  background-repeat: no-repeat;
  background-color: transparent;
  background-size: 0 var(--bg-height);
  animation: highlight 2000ms 1 ease-out;
  animation-delay: 400ms;
  animation-fill-mode: forwards;
  animation-play-state: paused;
}


@keyframes highlight {
  to {
    background-size: 100% var(--bg-height);
  }
}