.custom-modal-overlay {
	align-items: center;
	background: rgba(0, 0, 0, 0.35);
	display: none;
	inset: 0;
	justify-content: center;
	position: fixed;
	z-index: 3000;
}

.custom-modal-box {
	background: #fff;
	border: 1px solid rgba(0, 0, 0, 0.15);
	border-radius: 0.35rem;
	box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.2);
	max-width: min(420px, calc(100vw - 2rem));
	min-width: min(320px, calc(100vw - 2rem));
	overflow: hidden;
}

/* Les longues adresses URL demeurent visibles sans élargir les autres messages. */
.custom-modal-box.custom-modal-box-wide {
	max-width: min(800px, calc(100vw - 2rem));
	width: min(800px, calc(100vw - 2rem));
}

.custom-modal-header {
	border-bottom: 1px solid #dee2e6;
	font-weight: 600;
	padding: 0.65rem 0.85rem;
}

.custom-modal-body {
	padding: 0.85rem;
}

.custom-modal-footer {
	border-top: 1px solid #dee2e6;
	display: flex;
	gap: 0.5rem;
	justify-content: flex-end;
	padding: 0.65rem 0.85rem;
}

.custom-modal-button {
	background: #6c757d;
	border: 1px solid #6c757d;
	border-radius: 0.25rem;
	color: #fff;
	font-size: 0.875rem;
	line-height: 1.5;
	padding: 0.25rem 0.6rem;
}

.custom-modal-button-ok,
.custom-modal-button-yes {
	background: #0d6efd;
	border-color: #0d6efd;
}

.custom-modal-button-no {
	background: #6c757d;
	border-color: #6c757d;
}
/* Adaptations Sorrene : commandes compactes, texte long et petits écrans. */
.custom-modal-overlay { z-index: 100000; padding: 16px; }
.custom-modal-box { max-height: calc(100dvh - 32px); display: flex; flex-direction: column; color: #211d1a; }
.custom-modal-body { overflow-y: auto; white-space: pre-wrap; overflow-wrap: anywhere; }
.custom-modal-footer { flex-shrink: 0; flex-wrap: wrap; }
.custom-modal-button { min-height: 32px; padding: 4px 10px; line-height: 22px; }
.custom-modal-button-ok, .custom-modal-button-yes { background: #6a1a14; border-color: #6a1a14; }
