.tpt-quote-modal {
	position: fixed;
	z-index: 99999;
	left: 0;
	top: 0;
	width: 100%;
	height: 100%;
	overflow: auto;
	background-color: rgba(0, 0, 0, 0.4);
}

.tpt-quote-modal-content {
	background-color: #fefefe;
	margin: 5% auto;
	padding: 20px;
	border: 1px solid #888;
	width: 95%;
	max-width: 600px;
	max-height: 90vh;
	overflow-y: auto;
	position: relative;
	border-radius: 6px;
	box-sizing: border-box;
}

.tpt-quote-modal-title {
	color: inherit;
}

.tpt-quote-modal-content:focus {
	outline: none;
}

/* a real button, large enough for a finger, dark enough to read */
.tpt-quote-modal-close {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	flex: 0 0 auto;
	width: 44px;
	height: 44px;
	margin: -8px -8px -8px 8px;
	padding: 0;
	border: 0;
	border-radius: 50%;
	background: transparent;
	box-shadow: none;
	color: #50575e;
	font-size: 28px;
	font-weight: bold;
	line-height: 1;
	cursor: pointer;
}

.tpt-quote-modal-close:hover, .tpt-quote-modal-close:focus {
	background: rgba(0, 0, 0, .06);
	color: #000;
	text-decoration: none;
}

.tpt-quote-modal-close:focus-visible {
	outline: 2px solid currentColor;
	outline-offset: 2px;
}

/* the price under the product name: the theme often greys prices, which fails the contrast minimum here */
.tpt-quote-modal .tpt-quote-product-info .price,
.tpt-quote-modal .tpt-quote-product-info .price .amount,
.tpt-quote-modal .tpt-quote-variation-attributes {
	color: inherit;
}

.tpt-quote-form-message:empty {
	display: none;
}

.tpt-quote-error {
	margin-bottom: 10px;
	padding: 8px 12px;
	border-left: 3px solid #b32d2e;
	background: rgba(179, 45, 46, .06);
	color: #8a1f20;
	white-space: pre-line;
}

/* after sending: the request number and what was sent, in place of the form */
.tpt-quote-success {
	padding: 4px 0 8px;
}

.tpt-quote-success:focus {
	outline: none;
}

.tpt-quote-success__title {
	display: flex;
	align-items: center;
	gap: 8px;
	margin: 0 0 12px;
	font-size: 1.15em;
	font-weight: 700;
	color: #1a7f37;
}

.tpt-quote-success__title::before {
	content: "";
	flex: 0 0 auto;
	width: 20px;
	height: 20px;
	background: currentColor;
	-webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M5 12.5l4.5 4.5L19 7.5' fill='none' stroke='black' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / contain no-repeat;
	mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M5 12.5l4.5 4.5L19 7.5' fill='none' stroke='black' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / contain no-repeat;
}

.tpt-quote-success p {
	margin: 0 0 10px;
}

.tpt-quote-success__close {
	margin-top: 8px;
}

.tpt-quote-submit-note {
	margin: 8px 0 0;
	font-size: .9em;
	text-align: center;
}

/* the fields sit in two columns: a half-width field takes one, every other field the whole row */
.tpt-quote-fields-container {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	column-gap: 12px;
	container-type: inline-size;
}

.tpt-quote-field-wrapper {
	grid-column: 1 / -1;
	min-width: 0;
	margin-bottom: 15px;
}

.tpt-quote-field-wrapper--half {
	grid-column: auto;
}

/* too narrow for two columns: every field takes the whole row */
@container (max-width: 360px) {
	.tpt-quote-field-wrapper--half {
		grid-column: 1 / -1;
	}
}

.tpt-quote-field-wrapper label {
	display: block;
	margin-bottom: 5px;
	font-weight: bold;
}

.tpt-quote-field-wrapper input:not([type="radio"]):not([type="checkbox"]), .tpt-quote-field-wrapper textarea, .tpt-quote-field-wrapper select {
	width: 100% !important;
	max-width: 100% !important;
	box-sizing: border-box;
	padding: 8px;
	border: 1px solid #ccc;
	border-radius: 4px;
}

.tpt-radio-group label {
	display: flex;
	align-items: center;
	font-weight: normal;
	margin-bottom: 6px;
	cursor: pointer;
}

.tpt-radio-group input[type="radio"] {
	margin-right: 8px;
	margin-top: 0;
	margin-bottom: 0;
}

/* honeypot: off screen, never seen or reached by people */
.tpt-quote-hp {
	position: absolute !important;
	left: -9999px !important;
	width: 1px;
	height: 1px;
	overflow: hidden;
}
