/* The global reset removes dialog's automatic margins. Restore viewport centring. */
body dialog.ppf3-custom-modal[open] {
  position: fixed;
  inset: 0;
  margin: auto;
  box-sizing: border-box;
  width: min(560px, calc(100vw - 32px));
  max-width: calc(100vw - 32px);
  height: fit-content;
  max-height: calc(100dvh - 32px);
  overflow: auto;
  overscroll-behavior: contain;
  transform: none;
  padding: clamp(24px, 4vw, 40px);
}
body dialog.ppf3-custom-modal > .ppf3-close {
  margin: 0 0 24px auto;
}
@media (max-height: 480px) {
  body dialog.ppf3-custom-modal[open] { padding: 20px 24px; }
  body dialog.ppf3-custom-modal > .ppf3-close { margin-bottom: 16px; }
}
