/* Truck Engine Pro booking UI (lightweight; theme can enhance) */

.tep-booking-summary__rows {
	margin: 0;
}

.tep-booking-fields .required {
	color: #c00;
}

.tep-location-field__controls {
	display: flex;
	gap: 10px;
	align-items: center;
}

.tep-location-field__controls input[type="text"] {
	flex: 1;
	min-width: 0;
}

.tep-map-modal {
	display: none;
	position: fixed;
	inset: 0;
	z-index: 9999;
}

.tep-map-modal.is-open {
	display: block;
}

.tep-map-modal__overlay {
	position: absolute;
	inset: 0;
	background: rgba(0, 0, 0, 0.55);
}

.tep-map-modal__dialog {
	position: relative;
	background: #fff;
	max-width: 900px;
	width: calc(100% - 24px);
	margin: 24px auto;
	border-radius: 12px;
	overflow: hidden;
	box-shadow: 0 18px 60px rgba(0, 0, 0, 0.35);
	/* Prevent theme/animation transforms from breaking Leaflet tiling in Chrome */
	transform: none !important;
	filter: none !important;
	will-change: auto;
}

.tep-map-modal__header,
.tep-map-modal__footer {
	padding: 12px 14px;
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 10px;
	border-bottom: 1px solid #eee;
}

.tep-map-modal__footer {
	border-top: 1px solid #eee;
	border-bottom: 0;
	justify-content: flex-end;
}

.tep-map-modal__title {
	margin: 0;
	font-weight: 700;
}

.tep-map-modal__close {
	appearance: none;
	border: 0;
	background: transparent;
	font-size: 24px;
	line-height: 1;
	cursor: pointer;
}

.tep-map-modal__body {
	padding: 12px 14px;
}

.tep-map {
	width: 100%;
	height: 360px;
	border-radius: 10px;
	overflow: hidden;
	position: relative;
	background: #f3f4f6;
	contain: layout paint size;
}

.tep-map-modal.is-loading .tep-map::after {
	content: 'Loading map…';
	position: absolute;
	inset: 0;
	display: flex;
	align-items: center;
	justify-content: center;
	background: rgba(255, 255, 255, 0.75);
	color: #111;
	font-size: 14px;
	font-weight: 600;
	letter-spacing: 0.2px;
	backdrop-filter: none;
	pointer-events: none;
	text-align: center;
}

/* Avoid Chrome blur/freeze caused by inherited transforms/filters */
.tep-map .leaflet-container {
	transform: none;
	filter: none;
}

.tep-map-modal__address {
	margin: 10px 0 0;
	color: #444;
	font-size: 13px;
}

body.tep-modal-open {
	overflow: hidden;
}

/* Admin-only helper (only rendered for manage_options) */
.tep-admin-quote-tools {
	margin-top: 8px;
	display: flex;
	align-items: center;
	gap: 10px;
	flex-wrap: wrap;
}

.tep-admin-quote-tools__status {
	font-size: 12px;
	color: #333;
	opacity: 0;
	transition: opacity 0.15s ease;
}

.tep-admin-quote-tools__status.is-visible {
	opacity: 1;
}
