/* -----------------------------------------------------------------------
 * Cart hire widget — compact inline delivery option forms on the cart page
 * ---------------------------------------------------------------------- */

.wch-cart-hire-form {
	margin-top: 10px;
}

/* ---- Prompt (options missing) ---------------------------------------- */
.wch-cart-options-prompt {
	display: flex;
	align-items: center;
	gap: 6px;
	font-size: 12px;
	font-weight: 600;
	color: #c0392b;
	margin-bottom: 8px;
}

.wch-cart-options-prompt svg {
	flex-shrink: 0;
}

/* ---- Compact summary chips (options already set) ---------------------- */
.wch-cart-options-summary {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 6px;
	margin-bottom: 8px;
}

.wch-cart-opt-chip {
	display: inline-flex;
	align-items: center;
	gap: 4px;
	background: #ecedf9;
	border: 1.5px solid #1907c0;
	border-radius: 20px;
	padding: 3px 10px;
	font-size: 12px;
	color: #1907c0;
	font-weight: 600;
}

.wch-cart-edit-link {
	font-size: 12px;
	color: #1907c0;
	text-decoration: underline;
	cursor: pointer;
}

/* ---- Form body -------------------------------------------------------- */
.wch-cart-form-body {
	background: #f8f9ff;
	border: 1px solid #d4d6ea;
	border-radius: 10px;
	padding: 12px 14px;
	display: flex;
	flex-direction: column;
	gap: 10px;
}

/* Hide the auto-injected jQuery UI datepicker trigger button */
.wch-cart-form-body .ui-datepicker-trigger {
	display: none !important;
}

/* Hidden datepicker input — stays in DOM for correct calendar positioning */
.wch-cart-form-body .wch-cart-datepicker {
	opacity: 0;
	pointer-events: none;
	height: 0;
	padding: 0;
	margin: 0;
	border: 0;
	position: absolute;
}

/* ---- Form row — 3-column: label | control | price -------------------- */
.wch-form-row {
	display: flex;
	align-items: center;
	gap: 12px;
}

.wch-form-row--pills {
	align-items: flex-start;
}

.wch-form-label {
	font-size: 13px;
	font-weight: 500;
	color: #555;
	white-space: nowrap;
	width: 110px;
	flex-shrink: 0;
}

.wch-form-control {
	flex: 1;
	min-width: 0;
	display: flex;
	align-items: center;
	flex-wrap: wrap;
	gap: 8px;
}

.wch-form-control--date,
.wch-form-control--postcode {
	display: block;
}

.wch-form-price {
	width: 78px;
	flex-shrink: 0;
	text-align: right;
	font-size: 13px;
	font-weight: 700;
	color: #1a1a1a;
	white-space: nowrap;
}

/* ---- Save row (ack + save button at bottom) --------------------------- */
.wch-form-row--save {
	display: flex;
	align-items: flex-start;
	gap: 12px;
	border-top: 1px solid #e0e2f0;
	padding-top: 12px;
	margin-top: 2px;
}

.wch-form-row--save .wch-cart-ack-label {
	flex: 1;
}

.wch-form-save-actions {
	flex-shrink: 0;
	display: flex;
	flex-direction: column;
	align-items: flex-end;
	gap: 6px;
}

/* Hire-only save row (no ack) */
.wch-form-row--save:not(:has(.wch-cart-ack-label)) {
	justify-content: flex-end;
}

/* ---- Confirmed postcode display --------------------------------------- */
.wch-postcode-confirmed {
	display: flex;
	align-items: center;
	gap: 12px;
}

.wch-postcode-value {
	font-size: 15px;
	font-weight: 700;
	color: #1907c0;
	letter-spacing: 0.03em;
}

.wch-postcode-change {
	font-size: 12px;
	color: #0369a1;
	text-decoration: underline;
	cursor: pointer;
}

.wch-postcode-locked-note {
	font-size: 11px;
	color: #6b7280;
	font-style: italic;
}

.wch-cart-postcode.wch-pc-locked {
	background: #f3f4f6;
	color: #374151;
	cursor: default;
}

.wch-postcode-entry .wch-cart-postcode-row {
	display: flex;
	gap: 6px;
	align-items: center;
}

/* ---- Legacy field-row classes (kept for backward compat) -------------- */
.wch-cart-field-row {
	display: flex;
	align-items: center;
	gap: 10px;
	flex-wrap: wrap;
}

.wch-cart-field-label {
	font-weight: 600;
	font-size: 12px;
	color: #555;
	white-space: nowrap;
	width: 90px;
	flex-shrink: 0;
}

.wch-cart-field-control {
	flex: 1;
	min-width: 0;
}

/* ---- Date display ----------------------------------------------------- */
.wch-cart-date-display {
	display: flex;
	align-items: center;
	gap: 10px;
}

.wch-cart-date-text {
	font-size: 14px;
	font-weight: 700;
	color: #1907c0;
}

.wch-cart-date-sublabel {
	font-size: 12px;
	color: #555;
	font-weight: normal;
	display: flex;
	align-items: center;
	gap: 4px;
}

.wch-date-check {
	color: #16a34a;
	font-weight: 700;
	font-size: 13px;
}

.wch-cart-form-body .wch-change-date-btn {
	display: inline !important;
	background: transparent !important;
	border: none !important;
	color: #0369a1 !important;
	text-decoration: underline !important;
	padding: 0 !important;
	font-size: 12px;
	cursor: pointer;
	white-space: nowrap;
	flex-shrink: 0;
}

/* ---- Hire period pills ------------------------------------------------ */
.wch-cart-pills {
	display: flex;
	flex-wrap: wrap;
	gap: 6px;
}

.wch-cart-pills input[type="radio"] {
	position: absolute;
	opacity: 0;
	pointer-events: none;
	width: 0;
	height: 0;
}

.wch-cart-pill {
	display: flex;
	align-items: center;
	justify-content: center;
	background: #fff;
	border: 1.5px solid #d4d6ea;
	border-radius: 8px;
	padding: 6px 10px;
	cursor: pointer;
	transition: background 0.15s, border-color 0.15s;
	min-width: 0;
}

.wch-cart-pill-weeks {
	font-size: 12px;
	font-weight: 600;
	color: #1a1a1a;
	white-space: nowrap;
}

.wch-cart-pill-cost {
	display: none;
}

.wch-cart-pills input[type="radio"]:checked + .wch-cart-pill,
.wch-cart-pill.wch-pill-selected {
	background: #1907c0;
	border-color: #1907c0;
}

.wch-cart-pills input[type="radio"]:checked + .wch-cart-pill .wch-cart-pill-weeks,
.wch-cart-pill.wch-pill-selected .wch-cart-pill-weeks {
	color: #fff;
}

/* ---- Postcode row ----------------------------------------------------- */
.wch-cart-postcode-row {
	display: flex;
	gap: 6px;
	align-items: center;
}

.wch-cart-postcode-input {
	flex: 1;
	border: 1.5px solid #d4d6ea !important;
	border-radius: 6px !important;
	padding: 5px 10px !important;
	font-size: 13px !important;
	outline: none;
	min-width: 0;
}

.wch-cart-postcode-input:focus {
	border-color: #1907c0 !important;
}

.wch-cart-check-postcode {
	background: #1907c0;
	color: #fff;
	border: none;
	border-radius: 6px;
	padding: 5px 12px;
	font-size: 12px;
	font-weight: 600;
	cursor: pointer;
	white-space: nowrap;
	transition: background 0.15s;
}

.wch-cart-check-postcode:hover {
	background: #140ea0;
}

.wch-cart-postcode-notice {
	font-size: 11px;
	margin-top: 3px;
}

/* ---- Delivery result -------------------------------------------------- */
.wch-cart-delivery-result {
	background: #ecedf9;
	border-radius: 6px;
	padding: 6px 10px;
	display: flex;
	justify-content: space-between;
	align-items: center;
}

.wch-cart-delivery-area {
	font-size: 12px;
	color: #555;
}

.wch-cart-delivery-area strong {
	color: #1907c0;
	margin-left: 4px;
}

.wch-cart-delivery-fee {
	font-size: 13px;
	font-weight: 700;
	color: #1907c0;
}

/* ---- On-road permit row ---------------------------------------------- */
.wch-form-row--permit .wch-form-control {
	display: flex;
	align-items: center;
	gap: 10px;
	flex-wrap: wrap;
}

.wch-cart-permit-toggle {
	position: relative;
	display: inline-block;
	width: 40px;
	height: 22px;
	flex-shrink: 0;
}

.wch-cart-permit-toggle input {
	opacity: 0;
	width: 0;
	height: 0;
	position: absolute;
}

.wch-cart-permit-slider {
	position: absolute;
	inset: 0;
	background: #d4d6ea;
	border-radius: 22px;
	cursor: pointer;
	transition: background 0.2s;
}

.wch-cart-permit-slider::before {
	content: '';
	position: absolute;
	height: 16px;
	width: 16px;
	left: 3px;
	top: 3px;
	background: #fff;
	border-radius: 50%;
	transition: transform 0.2s;
}

.wch-cart-permit-toggle input:checked + .wch-cart-permit-slider {
	background: #1907c0;
}

.wch-cart-permit-toggle input:checked + .wch-cart-permit-slider::before {
	transform: translateX(18px);
}

.wch-cart-permit-label {
	font-size: 12px;
	color: #555;
}

/* ---- Restriction acknowledgment -------------------------------------- */
.wch-cart-ack-label {
	display: flex;
	align-items: flex-start;
	gap: 8px;
	font-size: 12px;
	color: #333;
	cursor: pointer;
	line-height: 1.5;
}

.wch-cart-ack-label input[type="checkbox"] {
	flex-shrink: 0;
	margin-top: 2px;
	width: 16px;
	height: 16px;
	accent-color: #1907c0;
	cursor: pointer;
}

/* ---- Save button ----------------------------------------------------- */
.wch-cart-save-btn {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	background: #1907c0;
	color: #fff;
	border: none;
	border-radius: 8px;
	padding: 9px 18px;
	font-size: 13px;
	font-weight: 600;
	cursor: pointer;
	transition: background 0.15s, opacity 0.15s;
	white-space: nowrap;
}

.wch-cart-save-btn:disabled {
	opacity: 0.4;
	cursor: not-allowed;
}

.wch-cart-save-btn:not(:disabled):hover {
	background: #140ea0;
}

.wch-cart-save-notice {
	font-size: 12px;
	font-weight: 600;
	text-align: right;
}

/* ---- Checkout button lock --------------------------------------------- */
.wch-checkout-locked {
	opacity: 0.5 !important;
	cursor: not-allowed !important;
	pointer-events: none !important;
}

.wch-checkout-notice {
	display: block;
	margin-top: 8px;
	font-size: 13px;
	color: #c0392b;
	font-weight: 600;
	text-align: center;
}
