/* DTH BYD — theme-owned FluentForm styling (BY-7 pattern; reproduces live free-FluentForm default pack, no Pro plugin). */

/* Labels */
.fluentform .ff-el-input--label label {
	font-family: "Montserrat", sans-serif;
	font-size: 17px;
	font-weight: 500;
	color: #2D3748;
}

/* Contact form (form 1) center-aligns its labels on live; scope the centering to
 * that form so the Dealer Registration form (left-aligned on live) is untouched. */
.fluent_form_1 .ff-el-input--label {
	text-align: center;
}

/* Text inputs / selects / textareas (font-family left as default — live uses the system stack) */
.fluentform .ff-el-form-control {
	font-size: 17px;
	color: #606266;
	background: #fff;
	border: 1px solid #DADBDD;
	border-radius: 7px;
	min-height: 44px;
	padding: 11px 15px;
}

/* Submit button */
.fluentform button[type="submit"],
.fluentform .ff-btn-submit {
	font-family: "Montserrat", sans-serif;
	font-size: 16px;
	font-weight: 500;
	line-height: 24px;
	color: #fff;
	background-color: #1A7EFB !important; /* match live: FluentForm free-pack default blue, not the brand blue */
	border: 1px solid transparent;
	border-radius: 7px;
	padding: 8px 20px;
}

.fluentform button[type="submit"]:hover,
.fluentform .ff-btn-submit:hover {
	background-color: #0e6ae9 !important;
}

/* -------------------------------------------------------------------------
 * Rebuilt dealer-registration form (BY-87) — the FluentForm-free replacement
 * rendered by template-parts/dealer-registration-form.php. Styled to match the
 * live form's look (Montserrat labels, same input shape, same submit blue).
 * ------------------------------------------------------------------------- */

/* Live renders the form as bare fields filling their column — no card, no
 * background, no padding, no max-width. Match that: the only framing we keep is
 * a vertical margin to clear the hero (live has the same clearance from block
 * spacing; without it WordPress's flow-column reset jams the form flush under
 * the hero). (BY-97, replacing the BY-90 card) */
.dth-reg {
	margin: 0 0 40px;
	box-sizing: border-box;
}

/* The form is the only child of its block column, and WordPress's layout CSS
 * zeroes the margin on a flow column's first/last child (a zero-specificity
 * :where() rule that still ties .dth-reg and wins on source order), which jams
 * the card flush under the hero. Re-assert the vertical gap at higher
 * specificity so the card clears the hero. (BY-90) */
.entry-content .dth-reg {
	margin-top: 0;
	margin-bottom: 40px;
}

/* Two-column block: Email + Dealership (left) · Phone + Position (right). */
.dth-reg-row {
	display: flex;
	flex-wrap: wrap;
	gap: 0 24px;
}

.dth-reg-col {
	flex: 1 1 calc(50% - 12px);
	min-width: 220px;
}

.dth-reg-field {
	margin: 0 0 20px; /* match FluentForm's 20px field rhythm (.ff-el-group margin-bottom) */
}

.dth-reg-field label {
	display: block;
	margin: 0 0 6px;
	font-family: "Montserrat", sans-serif;
	font-size: 17px;
	font-weight: 500;
	color: #2D3748;
}

.dth-reg-req {
	color: #d8282d;
}

.dth-reg-field input,
.dth-reg-field select,
.dth-reg-field textarea {
	display: block;
	width: 100%;
	box-sizing: border-box;
	/* textareas fall back to a monospace UA font; inherit the theme/body font so
	 * the Contact form's Message box matches the text inputs above it. */
	font-family: inherit;
	font-size: 17px;
	color: #606266;
	background: #fff;
	border: 1px solid #DADBDD;
	border-radius: 7px;
	min-height: 44px;
	padding: 11px 15px;
}

.dth-reg-field textarea {
	line-height: 1.5;
	resize: vertical;
}

.dth-reg-field input:focus,
.dth-reg-field select:focus,
.dth-reg-field textarea:focus {
	outline: none;
	border-color: #2B6CB0;
	box-shadow: 0 0 0 1px #2B6CB0;
}

/* Shipping-address group: grey panel wrapping the fields, with a label-style
 * heading — matching live byd.dthmedia.com.au (FluentForm's .grey-background
 * #E9E9E9 wrapper and its 17px/500 address label). (BY-97) */
.dth-reg-address {
	background: #E9E9E9;
	padding: 10px;
	margin: 0 0 20px;
}

.dth-reg-group-heading {
	font-family: "Montserrat", sans-serif;
	font-size: 17px;
	font-weight: 500;
	line-height: 1.6;
	color: #2D3748;
	margin: 0 0 10px;
}

.dth-reg-actions {
	margin-top: 8px;
}

.dth-reg-submit {
	font-family: "Montserrat", sans-serif;
	font-size: 16px;
	font-weight: 500;
	line-height: 24px;
	color: #fff;
	background-color: #1A7EFB;
	border: 1px solid transparent;
	border-radius: 7px;
	padding: 10px 28px;
	cursor: pointer;
}

.dth-reg-submit:hover {
	background-color: #0e6ae9;
}

/* Success / error notices from the handler redirect. */
.dth-reg-notice {
	border-radius: 7px;
	padding: 16px 18px;
	margin: 0 0 22px;
	font-size: 16px;
	line-height: 1.5;
}

.dth-reg-notice p {
	margin: 8px 0 0;
}

.dth-reg-notice--success {
	background: #ECFDF5;
	border: 1px solid #A7F3D0;
	color: #065F46;
}

.dth-reg-notice--error {
	background: #FEF2F2;
	border: 1px solid #FECACA;
	color: #991B1B;
}

@media (max-width: 600px) {
	.dth-reg-col {
		flex: 1 1 100%;
	}

	/* Tighter vertical gap on small screens (no card padding to trim now). (BY-97) */
	.dth-reg {
		margin: 24px 0;
	}

	.entry-content .dth-reg {
		margin-top: 24px;
		margin-bottom: 24px;
	}
}

/* -------------------------------------------------------------------------
 * Theme-owned Contact page (BY-87 follow-on) — the two-column section rendered
 * by [dealer_portal_contact]: the "Let's Connect" info panel beside the "Send us a
 * message" form. All colours/fonts are theme.json tokens:
 *   Montserrat headings, Open Sans body, BYD black --dark (#1A202C) for
 *   headings, subheads, icons and the phone link, muted body --muted (#4A5568),
 *   --light (#EDF2F7) hairline dividers. No grey card: the panel sits on the
 *   plain white page. Blue (--primary #2B6CB0) is reserved for buttons only.
 * ------------------------------------------------------------------------- */
/* Lift the section out of the 750px constrained content width so the two columns
 * have room to sit side by side (same breakout pattern as the cart/checkout/
 * single-product blocks: WP's :where() constrained max-width is zero-specificity,
 * so this single-class rule wins and centres it, scoped to this section). */
.dth-contact {
	max-width: 1080px;
	margin: 0 auto;
	/* Clear breathing room below the form before the dark footer. Padding (not
	 * margin) so it never collapses into the footer; one rhythm step up from the
	 * 40px field gap, holds at desktop + mobile. */
	padding-bottom: 72px;
	box-sizing: border-box;
}

.entry-content .dth-contact {
	max-width: 1080px;
	margin-left: auto;
	margin-right: auto;
	margin-bottom: 0;
	padding-bottom: 72px;
}

.dth-contact__grid {
	display: flex;
	flex-wrap: wrap;
	gap: 40px;
	align-items: flex-start;
}

/* Info panel ~ 2/5, form ~ 3/5 on desktop; both go full width when stacked. */
.dth-contact__col--info {
	flex: 1 1 320px;
	max-width: 420px;
}

.dth-contact__col--form {
	flex: 2 1 420px;
	min-width: 300px;
}

/* The form's own max-width margin isn't needed inside the grid cell. */
.dth-contact__col--form .dth-reg {
	margin: 0;
}

.dth-contact__col--form .entry-content .dth-reg,
.entry-content .dth-contact__col--form .dth-reg {
	margin: 0;
}

/* Column headings ("Let's Connect", "Send us a message") share one look:
 * Montserrat 700, brand navy, consistent size + rhythm. */
.dth-contact-info__heading,
.dth-contact__form-heading {
	font-family: "Montserrat", sans-serif;
	font-size: 30px;
	font-weight: 700;
	line-height: 1.3;
	color: #1A202C; /* --wp--preset--color--dark */
	margin: 0 0 24px;
}

/* ---- Info panel ---- */
/* No grey card: the panel sits on the plain white page background, flush with
 * the column grid, so it reads as part of the page not a boxed widget. (BY-87) */
.dth-contact-info {
	background: transparent;
	border: 0;
	border-radius: 0;
	padding: 0;
	font-family: "Open Sans", sans-serif;
	color: #4A5568; /* --wp--preset--color--muted */
}

.dth-contact-info__list {
	list-style: none;
	margin: 0 0 8px;
	padding: 0;
}

.dth-contact-info__item {
	display: flex;
	align-items: flex-start;
	gap: 14px;
	margin: 0 0 20px;
	font-size: 16px;
	line-height: 1.6;
}

.dth-contact-info__icon {
	flex: 0 0 auto;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 22px;
	height: 22px;
	margin-top: 2px;
	color: #1A202C; /* --wp--preset--color--dark (BYD black; blue is buttons only) */
}

.dth-contact-info__text {
	flex: 1 1 auto;
}

.dth-contact-info__phone {
	font-weight: 700;
	font-size: 18px;
	color: #1A202C; /* --wp--preset--color--dark */
	text-decoration: none;
}

.dth-contact-info__phone:hover {
	color: #1A202C; /* stay BYD black on hover; underline is the affordance */
	text-decoration: underline;
}

.dth-contact-info__org {
	display: block;
	font-weight: 700;
	color: #1A202C;
	margin-bottom: 2px;
}

.dth-contact-info__block {
	margin-top: 24px;
	padding-top: 24px;
	border-top: 1px solid #EDF2F7; /* --wp--preset--color--light */
}

/* Bold subheads ("Office Hours", "Corporate Information") in the heading font. */
.dth-contact-info__subhead {
	font-family: "Montserrat", sans-serif;
	font-size: 15px;
	font-weight: 700;
	letter-spacing: 0.02em;
	text-transform: uppercase;
	color: #1A202C; /* --wp--preset--color--dark (BYD black; blue is buttons only) */
	margin: 0 0 12px;
}

.dth-contact-info__hours {
	list-style: none;
	margin: 0;
	padding: 0;
	font-size: 16px;
	line-height: 1.5;
}

.dth-contact-info__hours li {
	display: flex;
	justify-content: space-between;
	gap: 16px;
	padding: 5px 0;
}

.dth-contact-info__hours li span:first-child {
	color: #2D3748; /* --wp--preset--color--dark-2 */
	font-weight: 600;
}

.dth-contact-info__hours li span:last-child {
	color: #4A5568; /* --wp--preset--color--muted */
}

.dth-contact-info__corp {
	margin: 0;
	font-size: 16px;
	line-height: 1.7;
	color: #4A5568;
}

/* Stack the two columns on tablet / mobile. */
@media (max-width: 782px) {
	.dth-contact,
	.entry-content .dth-contact {
		padding-bottom: 56px;
	}

	.dth-contact__grid {
		gap: 28px;
	}

	.dth-contact__col--info,
	.dth-contact__col--form {
		flex: 1 1 100%;
		max-width: 100%;
	}

	.dth-contact-info__heading,
	.dth-contact__form-heading {
		font-size: 26px;
		margin-bottom: 18px;
	}
}
