/* Chancery Contact Form v1.0.4 — Wise Digital Marketing */

.cfcf {
	--cfcf-primary: #A62461;
	--cfcf-secondary: #7ABFB8;
	--cfcf-text: #0D0D0D;
	--cfcf-muted: #5A5A5A;
	--cfcf-hint: #8A8A8A;
	--cfcf-border: #D4D4D4;
	--cfcf-border-hover: #A0A0A0;
	--cfcf-bg: #F5F4F2;
	--cfcf-surface: #FFFFFF;
	--cfcf-radius: 10px;
	font-family: 'Open Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
	color: var(--cfcf-text);
	box-sizing: border-box;
	line-height: 1.5;
	width: 100%;
}

.cfcf *,
.cfcf *::before,
.cfcf *::after {
	box-sizing: inherit;
}

.cfcf-card-wrap {
	background: var(--cfcf-bg);
	padding: 48px 32px;
	width: 100%;
}

/* ── Header ── */

.cfcf-badge {
	display: inline-flex;
	align-items: center;
	gap: 7px;
	background: rgba(122,191,184,0.16);
	color: #0F6E56;
	font-size: 12px;
	font-weight: 600;
	padding: 5px 13px;
	border-radius: 999px;
	margin-bottom: 14px;
}

.cfcf-badge-dot {
	width: 6px;
	height: 6px;
	border-radius: 50%;
	background: var(--cfcf-secondary);
	flex-shrink: 0;
}

.cfcf-title {
	font-family: 'Raleway', 'Open Sans', sans-serif;
	font-size: 26px;
	font-weight: 700;
	margin: 0 0 8px;
	color: var(--cfcf-text);
}

.cfcf-sub {
	font-size: 15px;
	color: var(--cfcf-muted);
	margin: 0 0 28px;
	line-height: 1.6;
}

/* ── Form body ── */

.cfcf-body {
	display: flex;
	flex-direction: column;
	gap: 22px;
	width: 100%;
}

.cfcf-lbl {
	font-size: 13px;
	font-weight: 600;
	color: var(--cfcf-muted);
	margin: 0 0 8px;
	line-height: 1.4;
}

.cfcf-opt-tag {
	font-weight: 400;
	color: var(--cfcf-hint);
}

/* ── Segmented controls ── */

.cfcf-seg {
	display: inline-flex;
	border: 1px solid var(--cfcf-border);
	border-radius: var(--cfcf-radius);
	overflow: hidden;
}

.cfcf-opt {
	appearance: none;
	background: var(--cfcf-surface);
	border: none;
	border-right: 1px solid var(--cfcf-border);
	padding: 10px 22px;
	font-size: 14px;
	font-family: inherit;
	color: var(--cfcf-text);
	cursor: pointer;
	transition: background 0.15s, color 0.15s;
	line-height: 1.3;
}

.cfcf-opt:last-child {
	border-right: none;
}

.cfcf-opt:hover {
	background: #EDECEB;
}

.cfcf-opt.is-on {
	background: var(--cfcf-primary);
	color: #fff;
}

/* ── Pills ── */

.cfcf-pills {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
}

.cfcf-pill {
	appearance: none;
	background: var(--cfcf-surface);
	border: 1px solid var(--cfcf-border);
	border-radius: 999px;
	padding: 9px 16px;
	font-size: 14px;
	font-family: inherit;
	color: var(--cfcf-text);
	cursor: pointer;
	transition: border-color 0.15s, background 0.15s, color 0.15s;
	line-height: 1.3;
}

.cfcf-pill:hover {
	border-color: var(--cfcf-primary);
}

.cfcf-pill.is-on {
	background: var(--cfcf-primary);
	border-color: var(--cfcf-primary);
	color: #fff;
}

/* ── Location cards (flagship) ── */

.cfcf-cards {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(145px, 1fr));
	gap: 10px;
}

.cfcf-card {
	appearance: none;
	background: var(--cfcf-surface);
	border: 1.5px solid var(--cfcf-border);
	border-radius: 12px;
	padding: 14px 15px;
	text-align: left;
	cursor: pointer;
	font-family: inherit;
	transition: border-color 0.15s, background 0.15s;
}

.cfcf-card:hover {
	border-color: var(--cfcf-primary);
}

.cfcf-card.is-on {
	border-color: var(--cfcf-primary);
	background: rgba(166,36,97,0.06);
}

.cfcf-card-name {
	display: block;
	font-size: 14px;
	font-weight: 600;
	color: var(--cfcf-text);
	line-height: 1.3;
}

.cfcf-card-sub {
	display: block;
	font-size: 12px;
	color: var(--cfcf-hint);
	margin-top: 2px;
}

/* ── Inputs ── */

.cfcf-row {
	display: flex;
	gap: 12px;
}

.cfcf-field {
	flex: 1;
	min-width: 0;
}

.cfcf-input {
	display: block;
	width: 100%;
	padding: 12px 16px;
	font-size: 15px;
	font-family: inherit;
	color: var(--cfcf-text);
	background: var(--cfcf-surface);
	border: 1px solid var(--cfcf-border);
	border-radius: var(--cfcf-radius);
	outline: none;
	transition: border-color 0.15s;
	-webkit-appearance: none;
	line-height: 1.4;
}

.cfcf-input::placeholder {
	color: var(--cfcf-hint);
}

.cfcf-input:focus {
	border-color: var(--cfcf-primary);
}

.cfcf-input.has-error {
	border-color: #D63031;
}

textarea.cfcf-input {
	resize: vertical;
	min-height: 64px;
}

/* ── Consent ── */

.cfcf-consent {
	display: flex;
	gap: 9px;
	align-items: flex-start;
	font-size: 12.5px;
	color: var(--cfcf-muted);
	line-height: 1.5;
	cursor: pointer;
}

.cfcf-consent input {
	margin-top: 2px;
	flex-shrink: 0;
}

/* ── Honeypot ── */

.cfcf-hp {
	position: absolute;
	left: -9999px;
	height: 0;
	width: 0;
	overflow: hidden;
}

/* ── Error ── */

.cfcf-error {
	font-size: 13px;
	color: #D63031;
	margin: 0;
	min-height: 0;
	transition: min-height 0.2s;
}

.cfcf-error:empty {
	display: none;
}

/* ── Submit ── */

.cfcf-submit {
	appearance: none;
	display: block;
	width: 100%;
	padding: 15px;
	background: var(--cfcf-primary);
	color: #fff;
	border: none;
	border-radius: var(--cfcf-radius);
	font-family: 'Raleway', 'Open Sans', sans-serif;
	font-size: 16px;
	font-weight: 600;
	cursor: pointer;
	transition: opacity 0.15s;
	line-height: 1.3;
}

.cfcf-submit:hover {
	opacity: 0.92;
}

.cfcf-submit:active {
	opacity: 0.85;
}

.cfcf-submit:disabled {
	opacity: 0.55;
	cursor: not-allowed;
}

.cfcf-submit.is-loading {
	position: relative;
	color: transparent;
}

.cfcf-submit.is-loading::after {
	content: '';
	position: absolute;
	inset: 0;
	margin: auto;
	width: 22px;
	height: 22px;
	border: 2.5px solid rgba(255,255,255,0.35);
	border-top-color: #fff;
	border-radius: 50%;
	animation: cfcf-spin 0.6s linear infinite;
}

@keyframes cfcf-spin {
	to { transform: rotate(360deg); }
}

/* ── Trust line ── */

.cfcf-trust {
	text-align: center;
	font-size: 12.5px;
	color: var(--cfcf-hint);
	margin: 0;
}

.cfcf-clock::before {
	content: '';
	display: inline-block;
	width: 14px;
	height: 14px;
	margin-right: 5px;
	vertical-align: -2px;
	background: currentColor;
	-webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round'%3E%3Ccircle cx='12' cy='12' r='10'/%3E%3Cpath d='M12 6v6l4 2'/%3E%3C/svg%3E") center/contain no-repeat;
	mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round'%3E%3Ccircle cx='12' cy='12' r='10'/%3E%3Cpath d='M12 6v6l4 2'/%3E%3C/svg%3E") center/contain no-repeat;
}

/* ── Enquiry type row ── */

.cfcf-enq {
	transition: opacity 0.2s;
}

/* ── Success state ── */

.cfcf-success {
	text-align: center;
	padding: 40px 12px;
}

.cfcf-success[hidden] {
	display: none;
}

.cfcf-tick {
	width: 56px;
	height: 56px;
	border-radius: 50%;
	background: rgba(122,191,184,0.18);
	margin: 0 auto 16px;
	position: relative;
}

.cfcf-tick::after {
	content: '';
	position: absolute;
	inset: 0;
	margin: auto;
	width: 28px;
	height: 28px;
	background: #0F6E56;
	-webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 6 9 17l-5-5'/%3E%3C/svg%3E") center/contain no-repeat;
	mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 6 9 17l-5-5'/%3E%3C/svg%3E") center/contain no-repeat;
}

.cfcf-success .cfcf-sub {
	max-width: 380px;
	margin-left: auto;
	margin-right: auto;
}

/* ── Responsive ── */

@media (min-width: 768px) {
	.cfcf-card-wrap {
		padding: 56px 48px;
	}

	.cfcf-title {
		font-size: 30px;
	}
}

@media (max-width: 767px) {
	.cfcf-card-wrap {
		padding: 32px 18px;
	}

	.cfcf-row {
		flex-direction: column;
	}

	.cfcf-seg {
		width: 100%;
	}

	.cfcf-opt {
		flex: 1;
		text-align: center;
		padding: 10px 10px;
	}

	.cfcf-cards {
		grid-template-columns: 1fr 1fr;
	}

	.cfcf-submit {
		padding: 16px;
		font-size: 16px;
	}

	.cfcf-title {
		font-size: 22px;
	}
}

@media (max-width: 400px) {
	.cfcf-cards {
		grid-template-columns: 1fr;
	}
}

/* ── Dark theme ── */

.cfcf.cfcf-theme-dark {
	--cfcf-text: #F0F0F0;
	--cfcf-muted: #B0B0B0;
	--cfcf-hint: #787878;
	--cfcf-border: #3A3A3A;
	--cfcf-border-hover: #555;
	--cfcf-bg: #141414;
	--cfcf-surface: #1E1E1E;
}

.cfcf-theme-dark .cfcf-card-wrap {
	background: var(--cfcf-bg);
}

.cfcf-theme-dark .cfcf-badge {
	background: rgba(122,191,184,0.12);
	color: #7ABFB8;
}

.cfcf-theme-dark .cfcf-opt {
	background: var(--cfcf-surface);
	color: var(--cfcf-muted);
}

.cfcf-theme-dark .cfcf-opt:hover {
	background: #2A2A2A;
}

.cfcf-theme-dark .cfcf-opt.is-on {
	background: var(--cfcf-primary);
	color: #fff;
}

.cfcf-theme-dark .cfcf-pill {
	background: var(--cfcf-surface);
	color: var(--cfcf-muted);
	border-color: var(--cfcf-border);
}

.cfcf-theme-dark .cfcf-pill:hover {
	border-color: var(--cfcf-primary);
}

.cfcf-theme-dark .cfcf-pill.is-on {
	background: var(--cfcf-primary);
	border-color: var(--cfcf-primary);
	color: #fff;
}

.cfcf-theme-dark .cfcf-card {
	background: var(--cfcf-surface);
	border-color: var(--cfcf-border);
}

.cfcf-theme-dark .cfcf-card:hover {
	border-color: var(--cfcf-primary);
}

.cfcf-theme-dark .cfcf-card.is-on {
	border-color: var(--cfcf-primary);
	background: rgba(166,36,97,0.18);
}

.cfcf-theme-dark .cfcf-card-name {
	color: var(--cfcf-text);
}

.cfcf-theme-dark .cfcf-input {
	background: var(--cfcf-surface);
	border-color: var(--cfcf-border);
	color: var(--cfcf-text);
}

.cfcf-theme-dark .cfcf-input::placeholder {
	color: var(--cfcf-hint);
}

.cfcf-theme-dark .cfcf-input:focus {
	border-color: var(--cfcf-primary);
}

.cfcf-theme-dark .cfcf-consent {
	color: var(--cfcf-muted);
}

.cfcf-theme-dark .cfcf-tick {
	background: rgba(122,191,184,0.12);
}

.cfcf-theme-dark .cfcf-success .cfcf-title {
	color: var(--cfcf-text);
}
