/* Native dialogs share the reference panels' size and placement. */
dialog:not([open]), [hidden] {
  display: none !important;
}

dialog {
  margin: 0;
  right: auto;
  bottom: auto;
  color: inherit;
}

#cookie-preferences::backdrop {
  background: rgb(0 0 0 / 80%);
}

#loan-promotion {
  padding: 0;
  border: 0;
  background: transparent;
  width: max-content;
}

#loan-promotion::backdrop {
  background: rgb(0 0 0 / 50%);
}

html:has(dialog[open]) {
  overflow: hidden;
}

[data-reveal].awaiting-scroll {
  opacity: 0;
  transform: translateY(2rem);
}

/* Show all the content when animation or scripting is unavailable. */
@media (prefers-reduced-motion: reduce), (scripting: none) {
  .scroll-animate, [data-reveal].awaiting-scroll {
    opacity: 1;
    transform: none;
  }
  .scroll-animate.animate-in > * {
    animation: none;
  }
}
