/* FO-14899 proof of concept: rounder corners and more padding on every legacy Bootstrap modal, as on the retro modal.
   Add the class modal-classic to a .modal to keep the old look. Twig modals (.ds-modal) and iframe modals (.iframe-modal, header over the iframe) have their own design.
   :where() keeps the specificity of the Bootstrap selectors, so page-specific modal rules still win. */
.modal:where(:not(.modal-classic, .ds-modal, .iframe-modal)) {
	--modalRadius: 14px;
	--modalPadding: clamp(15px, 2vw, 20px);
	--modalBodyTop: 18px;
	border: none;
	border-radius: var(--modalRadius);
	box-shadow: 0 18px 48px rgba(24, 22, 64, .22);
}
.modal:where(:not(.modal-classic, .ds-modal, .iframe-modal)) .modal-header {
	padding: 22px var(--modalPadding) 14px;
	border-radius: var(--modalRadius) var(--modalRadius) 0 0;
}
.modal:where(:not(.modal-classic, .ds-modal, .iframe-modal)) .modal-body {
	padding: 0 var(--modalPadding) var(--modalBodyTop);
	box-sizing: border-box;
	overflow-x: auto;
}
/* A spacer instead of top padding, as in lon.css: a sticky table header then sticks at top 0
   both when the body scrolls and when a wrapper div inside it scrolls */
.modal:where(:not(.modal-classic, .ds-modal, .iframe-modal)) .modal-body::before {
	height: var(--modalBodyTop);
}
.modal:where(:not(.modal-classic, .ds-modal, .iframe-modal)) .modal-body > :last-child {
	margin-bottom: 0;
}
.modal:where(:not(.modal-classic, .ds-modal, .iframe-modal)) .modal-footer {
	padding: 14px var(--modalPadding);
	border-radius: 0 0 var(--modalRadius) var(--modalRadius);
}
/* lon.css sticks table headers 12px above the scroll edge, which hides the top of the header */
.modal:where(:not(.modal-classic, .ds-modal, .iframe-modal)) .modal-body table :is(thead, th) {
	top: 0;
}
