/**
 * Mr Mobility — delivery estimate module.
 *
 * SIZES ARE IN px, DELIBERATELY. WoodMart sets
 *   html { font-size: var(--wd-text-font-size) }  // 19px on this site
 * so rem units render ~19% larger than the browser default they were designed
 * against. These px values match the approved design exactly.
 *
 * Every colour reads a site design token with a literal fallback, so the module
 * follows the brand palette but still renders correctly if a token is renamed.
 * The only hardcoded colour is the in-stock green: the palette has no
 * positive-status tone.
 */

/* The theme styles the product summary column bold. These are set explicitly
   so the module renders at its designed weights rather than inheriting. */
.mrm-delivery {
	display: flex;
	flex-direction: column;
	gap: 5px;
	margin-top: 18px;
	font-family: inherit;
	font-style: normal;
	letter-spacing: normal;
	text-transform: none;
	color: var(--ink, #233550);
}

.mrm-delivery[hidden] {
	display: none;
}

/* Inline flow, not flex: the label and the control share one text line, so the
   browser's own baseline alignment is what we want. align-items:center lines up
   boxes, which leaves the city sitting fractionally high. */
.mrm-delivery .mrm-head {
	font-size: 14px;
	font-weight: 700;
	line-height: 1.4;
	color: var(--muted, #5e6b7a);
}

.mrm-delivery .mrm-shell {
	position: relative;
	display: inline-block;
	vertical-align: baseline;
	margin: 0;
	padding: 0;
	border: 0;
	background: none;
	max-width: none;
}

/* Themes style <select> heavily — WoodMart gives it a box, a fixed height and
   its own dropdown arrow via a background image. This needs to read as inline
   text, so those are overridden explicitly. !important is deliberate and scoped
   to this one control; without it the theme's form rules win on specificity. */
.mrm-delivery .mrm-shell select,
.mrm-delivery select {
	appearance: none !important;
	-webkit-appearance: none !important;
	-moz-appearance: none !important;
	font: inherit !important;
	font-size: inherit !important;
	font-weight: 800 !important;
	line-height: 1.4 !important;
	letter-spacing: inherit !important;
	text-transform: none !important;
	vertical-align: baseline !important;
	color: var(--a2, #3E7FA7) !important;
	background: none !important;
	background-image: none !important;
	background-color: transparent !important;
	border: 0 !important;
	border-radius: 0 !important;
	box-shadow: none !important;
	outline: none;
	padding: 0 15px 1px 1px !important;
	margin: 0 !important;
	width: auto !important;
	min-width: 0 !important;
	max-width: none !important;
	height: auto !important;
	min-height: 0 !important;
	cursor: pointer;
	transition: color .18s;
}

.mrm-delivery .mrm-shell select:hover,
.mrm-delivery select:hover {
	color: var(--a3, #4CA5D3) !important;
	background: none !important;
	border: 0 !important;
}

.mrm-delivery select:focus,
.mrm-delivery select:focus-visible {
	outline: 3px solid var(--a1, #305A7B);
	outline-offset: 3px;
	box-shadow: none !important;
	border: 0 !important;
}

/* Some themes wrap selects in their own styled container. */
.mrm-delivery .mrm-shell::before,
.mrm-delivery .mrm-shell::after,
.mrm-delivery select::-ms-expand {
	display: none !important;
}

.mrm-delivery .mrm-chev {
	position: absolute;
	right: 0;
	top: 50%;
	transform: translateY(-50%);
	width: 11px;
	height: 11px;
	color: var(--a2, #3E7FA7);
	pointer-events: none;
	transition: .18s;
	z-index: 1;
}

.mrm-delivery .mrm-shell:hover .mrm-chev {
	color: var(--a3, #4CA5D3);
}

.mrm-delivery .mrm-date {
	font-size: 20px;
	line-height: 1.25;
	font-weight: 800;
	letter-spacing: -.012em;
	color: var(--a1, #305A7B);
	text-wrap: balance;
}

.mrm-delivery .mrm-note {
	font-size: 12.8px;
	font-weight: 700;
	color: var(--muted, #5e6b7a);
	opacity: .92;
}

.mrm-delivery .mrm-status {
	font-size: 13.6px;
	font-weight: 700;
	color: var(--muted, #5e6b7a);
	margin-top: 11px;
	padding-top: 11px;
	border-top: 1px solid var(--line, #e7ecf1);
}

.mrm-delivery .mrm-ok {
	color: #0E7457;
	font-weight: 700;
}

.mrm-delivery .mrm-tick {
	width: 14px;
	height: 14px;
	flex: none;
	vertical-align: -2px;
	margin-right: 4px;
}

.mrm-delivery .mrm-sep {
	opacity: .4;
	margin: 0 5px;
}

.mrm-delivery strong {
	font-weight: 800;
	color: var(--a1, #305A7B);
	font-variant-numeric: tabular-nums;
}

@media (prefers-reduced-motion: reduce) {
	.mrm-delivery * {
		transition: none !important;
	}
}

/* ---------------------------------------------------------------------------
 * Size variants
 *
 * Base rules above are "compact" — the sizes from the approved design. The page
 * body runs at 19px (WoodMart's --wd-text-font-size), so compact sits noticeably
 * below the surrounding copy. "Larger" lifts everything ~15% to sit closer to it.
 * Selected under WooCommerce -> Delivery Estimates.
 * ------------------------------------------------------------------------- */

.mrm-delivery.mrm-size-larger .mrm-head   { font-size: 16px; }
.mrm-delivery.mrm-size-larger .mrm-date   { font-size: 23px; }
.mrm-delivery.mrm-size-larger .mrm-note   { font-size: 14.5px; }
.mrm-delivery.mrm-size-larger .mrm-status { font-size: 15.5px; }
.mrm-delivery.mrm-size-larger .mrm-tick   { width: 16px; height: 16px; }
.mrm-delivery.mrm-size-larger .mrm-chev   { width: 12px; height: 12px; }
