/*
 * The host a UUI dialog is mounted into.
 *
 * `showModalComponent(…, uui)` keeps appending to `.modal_ground`, because that element
 * is what `hideModal()`, same-group replacement and modal stacking are keyed on — 179
 * call sites depend on it. What it must not keep is the legacy scrim: `.modal_ground`
 * already paints `rgba(7,21,36,.51)` with a 6px backdrop blur in shared.css, and
 * `uui-modal-overlay` paints its own from Figma. Two scrims stack into a much darker
 * page than either design intends.
 *
 * So this file removes exactly the legacy paint and nothing else. The positioning and
 * the z-index stay: they are the host's job in both shells.
 *
 * It lives in 00_public because dialogs appear on public pages too, and it is deliberately
 * *not* part of uui.min.css — that bundle must stay renderable on its own, and a rule
 * whose whole purpose is to undo a legacy stylesheet has no meaning in the clean room.
 */

.modal_ground.uui_ground {
	background: none;
	backdrop-filter: none;
	-webkit-backdrop-filter: none;
}

/*
 * The wrapper UuiModalDialog adds when a caller passed raw-HTML `introContent`.
 *
 * It carries no padding of its own: since `uui-modal-body.css` the dialog body insets and
 * spaces its children, so a second inset here would double to 48px. What the wrapper does owe
 * its two children — the intro and the body — is the same rhythm, because it is one grid item
 * from the body's point of view and nothing inside it would otherwise be spaced.
 */
.pc-uui-dialog__body {
	display: grid;
	gap: var(--uui-spacing-2xl);
}

/*
 * `showCompactPopup` builds its own ✕ into the message markup, not into the shell. The
 * legacy dialog has no close affordance of its own, so there it is the only one; the UUI
 * header draws a real `uui-button-close`, so there it is a second one — unstyled, because
 * `.rd-compact-popup-closelink` lives in the site sheets and the clean room has none.
 *
 * Hidden rather than removed from `showCompactPopup`: that function serves both shells,
 * and taking the link out would leave the legacy dialog without a way to close.
 */
.modal_ground.uui_ground .rd-compact-popup-closelink {
	display: none;
}

/*
 * The compact popup's message needs no padding of its own any more: `uui-modal-body.css`
 * gives every dialog body the 24px inset Figma puts on the header and the actions. It kept one
 * here while the body had none, and leaving it would now inset the message twice.
 */
