/**
 * Trim & Tuck — Book a Free Measurement form styles.
 */

.ttmb-form-wrap {
	--ttmb-primary: #5a1a1a;
	--ttmb-accent: #e67e22;
	--ttmb-bg: #f2eadf;
	--ttmb-card-bg: #fbf8f5;
	--ttmb-border: #d9ccc0;
	--ttmb-text: #333;
	--ttmb-muted: #7a6a5e;
	--ttmb-error: #b32d2e;

	max-width: 1140px;
	margin: 0 auto;
	color: var(--ttmb-text);
	font-size: 16px;
	line-height: 1.5;
	background: var(--ttmb-bg);
	padding: 28px;
	border-radius: 10px;
	box-sizing: border-box;
}

.ttmb-form-wrap *,
.ttmb-form-wrap *::before,
.ttmb-form-wrap *::after {
	box-sizing: border-box;
}

.ttmb-title {
	margin: 0 0 6px;
	color: var(--ttmb-primary);
	text-align: center;
}

.ttmb-subtitle {
	margin: 0 0 20px;
	text-align: center;
	color: var(--ttmb-muted);
}

/* Progress steps */
.ttmb-steps {
	display: flex;
	flex-wrap: wrap;
	gap: 8px 4px;
	list-style: none;
	margin: 0 0 24px;
	padding: 0 0 16px;
	border-bottom: 1px solid var(--ttmb-border);
	counter-reset: none;
}

.ttmb-steps__item {
	display: flex;
	align-items: center;
	gap: 8px;
	flex: 1 1 auto;
	min-width: 140px;
	color: var(--ttmb-muted);
	font-size: 14px;
}

.ttmb-steps__num {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 30px;
	height: 30px;
	border-radius: 50%;
	border: 2px solid var(--ttmb-border);
	background: #fff;
	font-weight: 700;
	flex: 0 0 auto;
}

.ttmb-steps__item.is-active .ttmb-steps__num,
.ttmb-steps__item.is-complete .ttmb-steps__num {
	background: var(--ttmb-primary);
	border-color: var(--ttmb-primary);
	color: #fff;
}

.ttmb-steps__item.is-active { color: var(--ttmb-primary); font-weight: 600; }

/* Multi-select hint under a legend */
.ttmb-hint {
	margin: -12px 0 18px;
	text-align: center;
	color: var(--ttmb-muted);
	font-size: 14px;
}

/* Steps */
.ttmb-step { display: none; border: 0; padding: 0; margin: 0; }
.ttmb-step.is-active { display: block; }

.ttmb-legend {
	display: block;
	width: 100%;
	text-align: center;
	font-size: 20px;
	font-weight: 600;
	color: var(--ttmb-primary);
	margin: 0 0 20px;
	padding: 0;
}

/* Grid + fields */
.ttmb-grid { display: flex; flex-wrap: wrap; gap: 16px; }
.ttmb-field { margin-bottom: 16px; flex: 1 1 100%; }
.ttmb-col-6 { flex: 1 1 calc(50% - 8px); }
.ttmb-col-12 { flex: 1 1 100%; }

.ttmb-field label {
	display: block;
	font-weight: 600;
	margin-bottom: 6px;
	color: var(--ttmb-primary);
}

.ttmb-field label.ttmb-sublabel {
	font-weight: 500;
	font-size: 14px;
	color: var(--ttmb-muted);
}

.ttmb-req { color: var(--ttmb-error); }

.ttmb-form-wrap input[type="text"],
.ttmb-form-wrap input[type="email"],
.ttmb-form-wrap input[type="tel"],
.ttmb-form-wrap input[type="date"],
.ttmb-form-wrap select,
.ttmb-form-wrap textarea {
	width: 100%;
	padding: 12px 14px;
	border: 1px solid var(--ttmb-border);
	border-radius: 6px;
	background: #fff;
	font: inherit;
	color: var(--ttmb-text);
}

.ttmb-form-wrap input:focus,
.ttmb-form-wrap select:focus,
.ttmb-form-wrap textarea:focus {
	outline: none;
	border-color: var(--ttmb-accent);
	box-shadow: 0 0 0 3px rgba(230, 126, 34, 0.2);
}

.ttmb-form-wrap .ttmb-invalid input,
.ttmb-form-wrap input.ttmb-invalid,
.ttmb-form-wrap select.ttmb-invalid {
	border-color: var(--ttmb-error);
}

.ttmb-error {
	color: var(--ttmb-error);
	font-size: 13px;
	margin: 6px 0 0;
}

.ttmb-form-error {
	color: var(--ttmb-error);
	background: #fdecec;
	border: 1px solid #f3c6c6;
	padding: 10px 14px;
	border-radius: 6px;
	margin-top: 16px;
}

/* Cards */
.ttmb-cards {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
	gap: 14px;
	margin-bottom: 8px;
}

.ttmb-card {
	position: relative;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	gap: 10px;
	text-align: center;
	padding: 20px 12px;
	border: 2px solid var(--ttmb-border);
	border-radius: 10px;
	background: var(--ttmb-card-bg);
	cursor: pointer;
	transition: border-color .15s, box-shadow .15s, transform .05s;
	color: var(--ttmb-primary);
	font-weight: 600;
}

.ttmb-card:hover { border-color: var(--ttmb-accent); }
.ttmb-card:active { transform: scale(0.99); }

.ttmb-card input[type="radio"],
.ttmb-card input[type="checkbox"] {
	position: absolute;
	opacity: 0;
	width: 1px;
	height: 1px;
}

.ttmb-card__icon { color: var(--ttmb-primary); }
.ttmb-card__icon .ttmb-icon { width: 46px; height: 46px; }
.ttmb-card__label { font-size: 15px; line-height: 1.3; }

.ttmb-card.is-selected,
.ttmb-card:has(input:checked) {
	border-color: var(--ttmb-primary);
	background: #fff;
	box-shadow: 0 0 0 3px rgba(90, 26, 26, 0.12);
}

.ttmb-card:focus-within {
	border-color: var(--ttmb-accent);
	box-shadow: 0 0 0 3px rgba(230, 126, 34, 0.25);
}

/* Navigation buttons */
.ttmb-nav {
	display: flex;
	justify-content: space-between;
	align-items: center;
	gap: 12px;
	margin-top: 24px;
}

.ttmb-btn {
	appearance: none;
	border: 0;
	border-radius: 30px;
	padding: 13px 34px;
	font: inherit;
	font-weight: 700;
	cursor: pointer;
	background: var(--ttmb-primary);
	color: #fff;
	transition: opacity .15s, background .15s;
}

.ttmb-btn:hover { opacity: .92; }
.ttmb-btn:disabled { opacity: .6; cursor: default; }

.ttmb-btn--ghost {
	background: #fff;
	color: var(--ttmb-primary);
	border: 1px solid var(--ttmb-border);
}

.ttmb-submit { background: var(--ttmb-accent); }

/* Honeypot */
.ttmb-hp {
	position: absolute !important;
	left: -9999px !important;
	top: auto;
	width: 1px;
	height: 1px;
	overflow: hidden;
}

/* Turnstile */
.ttmb-turnstile-wrap { margin-top: 20px; }

/* Success */
.ttmb-success {
	text-align: center;
	padding: 40px 20px;
}
.ttmb-success__icon svg { width: 64px; height: 64px; color: #1a7f37; }
.ttmb-success__heading { color: var(--ttmb-primary); margin: 12px 0 8px; }
.ttmb-success__message { color: var(--ttmb-muted); max-width: 520px; margin: 0 auto; }

/* ------------------------------------------------------------------ *
 * Contact form ("Get in touch")
 * Condensed, transparent variant intended to sit sitewide in the footer
 * on the dark maroon block. Scoped to .ttmb-contact-wrap so the
 * measurement wizard is unaffected.
 * ------------------------------------------------------------------ */

/* Transparent, edge-to-edge: no card background / padding / max-width. */
.ttmb-form-wrap.ttmb-contact-wrap {
	background: transparent;
	max-width: 100%;
	padding: 0;
	border-radius: 0;
}

/* Labels move inside the fields as placeholders; keep them in the DOM,
   visually hidden, so screen readers still announce each field. */
.ttmb-contact-wrap .ttmb-field > label {
	position: absolute !important;
	width: 1px;
	height: 1px;
	padding: 0;
	margin: -1px;
	overflow: hidden;
	clip: rect(0 0 0 0);
	white-space: nowrap;
	border: 0;
}

/* Tighter vertical rhythm than the wizard. */
.ttmb-contact-wrap .ttmb-grid { gap: 12px; }
.ttmb-contact-wrap .ttmb-field { margin-bottom: 0; }
.ttmb-contact-wrap .ttmb-turnstile-wrap { margin-top: 14px; }
.ttmb-contact-wrap .ttmb-nav { margin-top: 16px; }

/* Slightly shorter message box. */
.ttmb-contact-wrap textarea { min-height: 92px; }

/* Since the labels are now placeholders, darken them so they read clearly on
   the white fields (browsers default placeholders to a faint grey). */
.ttmb-contact-wrap input::placeholder,
.ttmb-contact-wrap textarea::placeholder {
	color: #555;
	opacity: 1; /* Firefox lowers placeholder opacity by default. */
}

/* Gold Send button. !important so the theme's own button reset (e.g. Elementor,
   which can strip the background to transparent) cannot override it. */
.ttmb-contact-wrap .ttmb-submit {
	background: #a78952 !important;
	color: #fff !important;
}

/* Legibility on the dark footer (the card background is now transparent). */
.ttmb-contact-wrap .ttmb-title,
.ttmb-contact-wrap .ttmb-success__heading { color: #fff; }
.ttmb-contact-wrap .ttmb-subtitle,
.ttmb-contact-wrap .ttmb-success__message { color: rgba(255, 255, 255, 0.85); }
.ttmb-contact-wrap .ttmb-error { color: #ffd9d9; }

/* Responsive */
@media (max-width: 600px) {
	.ttmb-form-wrap { padding: 18px; }
	.ttmb-form-wrap.ttmb-contact-wrap { padding: 0; }
	.ttmb-col-6 { flex: 1 1 100%; }
	/* Stack the progress steps vertically, each showing its number and title
	   (matches the previous form; avoids the numbers-only row on small screens). */
	.ttmb-steps { flex-direction: column; align-items: stretch; gap: 12px; }
	.ttmb-steps__item { min-width: 0; flex: 0 0 auto; width: 100%; }
	.ttmb-btn { padding: 12px 24px; }
}
