/*
 * Minimal Bootstrap 5.3 modal styles for the cart journey's popups
 * (out-of-area #postcodemodal, #newMarketModal, #forgotPasswordModal).
 * The live site loads full Bootstrap CSS from its theme; the rebuilt
 * Elementor pages do not, and pulling all of Bootstrap in would fight
 * the reskin's styles — so only the modal component subset is shipped.
 */

.modal {
	position: fixed;
	top: 0;
	left: 0;
	z-index: 1055;
	display: none;
	width: 100%;
	height: 100%;
	overflow-x: hidden;
	overflow-y: auto;
	outline: 0;
}
.modal-dialog {
	position: relative;
	width: auto;
	margin: 0.5rem;
	pointer-events: none;
}
.modal.fade .modal-dialog {
	transition: transform 0.3s ease-out;
	transform: translate(0, -50px);
}
.modal.show .modal-dialog {
	transform: none;
}
.modal-dialog-centered {
	display: flex;
	align-items: center;
	min-height: calc(100% - 1rem);
}
.modal-content {
	position: relative;
	display: flex;
	flex-direction: column;
	width: 100%;
	pointer-events: auto;
	background-color: #fff;
	background-clip: padding-box;
	border: 1px solid rgba(0, 0, 0, 0.175);
	border-radius: 0.5rem;
	outline: 0;
}
.modal-header {
	display: flex;
	flex-shrink: 0;
	align-items: center;
	justify-content: space-between;
	padding: 1rem;
	border-bottom: 1px solid #dee2e6;
	border-top-left-radius: 0.5rem;
	border-top-right-radius: 0.5rem;
}
.modal-title {
	margin: 0;
	line-height: 1.5;
	color: #0f3014;
}
.modal-body {
	position: relative;
	flex: 1 1 auto;
	padding: 1rem;
	color: #03312e;
}
.modal-backdrop {
	position: fixed;
	top: 0;
	left: 0;
	z-index: 1050;
	width: 100vw;
	height: 100vh;
	background-color: #000;
}
.modal-backdrop.fade { opacity: 0; }
.modal-backdrop.show { opacity: 0.5; }
.modal.fade { transition: opacity 0.15s linear; }
.modal.fade:not(.show) { opacity: 0; }
body.modal-open { overflow: hidden; }

.modal .btn-close {
	box-sizing: content-box;
	width: 1em;
	height: 1em;
	padding: 0.25em;
	background: transparent url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23000'%3e%3cpath d='M.293.293a1 1 0 0 1 1.414 0L8 6.586 14.293.293a1 1 0 1 1 1.414 1.414L9.414 8l6.293 6.293a1 1 0 0 1-1.414 1.414L8 9.414l-6.293 6.293a1 1 0 0 1-1.414-1.414L6.586 8 .293 1.707a1 1 0 0 1 0-1.414z'/%3e%3c/svg%3e") center / 1em auto no-repeat;
	border: 0;
	border-radius: 0.375rem;
	opacity: 0.5;
	cursor: pointer;
}
.modal .btn-close:hover { opacity: 0.8; }

.modal .btn {
	display: inline-block;
	padding: 0.375rem 0.75rem;
	font-size: 1rem;
	line-height: 1.5;
	border: 1px solid transparent;
	border-radius: 0.375rem;
	cursor: pointer;
	margin-top: 0.5rem;
}
.modal .btn-primary {
	color: #fff;
	background-color: #78be20;
	border-color: #78be20;
}
.modal .btn-danger {
	color: #fff;
	background-color: #dc3545;
	border-color: #dc3545;
	margin-left: 0.5rem;
}
.modal .form-control {
	display: block;
	width: 100%;
	padding: 0.375rem 0.75rem;
	margin: 0.5rem 0;
	border: 1px solid #ced4da;
	border-radius: 0.375rem;
	font-size: 1rem;
}
.modal .forgoterror { color: #dc3545; }

@media (min-width: 576px) {
	.modal-dialog { max-width: 500px; margin: 1.75rem auto; }
	.modal-dialog-centered { min-height: calc(100% - 3.5rem); }
	.modal-sm { max-width: 300px; }
}
