/* Diabetes Clarity Contact Form — matches the site's Kadence palette */
.dcf {
	--dcf-primary: var(--global-palette1, #2B6CB0);
	--dcf-primary-dark: var(--global-palette2, #215387);
	--dcf-heading: var(--global-palette3, #1A202C);
	--dcf-text: var(--global-palette4, #2D3748);
	--dcf-muted: var(--global-palette5, #4A5568);
	--dcf-subtle: var(--global-palette6, #718096);
	--dcf-line: var(--global-palette7, #EDF2F7);
	--dcf-bg: var(--global-palette8, #F7FAFC);
	--dcf-white: var(--global-palette9, #ffffff);
	--dcf-error: #C53030;
	--dcf-error-bg: #FFF5F5;

	max-width: 720px;
	margin: 0 auto;
	padding: clamp(24px, 4vw, 40px);
	background: var(--dcf-white);
	border: 1px solid var(--dcf-line);
	border-radius: 16px;
	box-shadow: 0 1px 2px rgba(26, 32, 44, .04), 0 8px 24px rgba(26, 32, 44, .06);
	color: var(--dcf-text);
	font-family: inherit;
	line-height: 1.6;
	box-sizing: border-box;
}
.dcf *, .dcf *::before, .dcf *::after { box-sizing: border-box; }

.dcf-title {
	margin: 0 0 8px;
	color: var(--dcf-heading);
	font-size: clamp(1.5rem, 3vw, 1.875rem);
	line-height: 1.25;
}
.dcf-intro { margin: 0 0 28px; color: var(--dcf-muted); font-size: 1rem; }

.dcf-form { display: flex; flex-direction: column; gap: 20px; margin: 0; }
.dcf-row { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }

.dcf-field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.dcf-field > label {
	color: var(--dcf-heading);
	font-size: .9375rem;
	font-weight: 600;
}
.dcf-req { color: var(--dcf-primary); }
.dcf-opt { color: var(--dcf-subtle); font-weight: 400; font-size: .875rem; }

.dcf input[type="text"],
.dcf input[type="email"],
.dcf input[type="tel"],
.dcf select,
.dcf textarea {
	width: 100%;
	margin: 0;
	padding: 12px 14px;
	border: 1px solid #CBD5E0;
	border-radius: 10px;
	background: var(--dcf-white);
	color: var(--dcf-heading);
	font: inherit;
	font-size: 1rem;
	line-height: 1.4;
	box-shadow: none;
	transition: border-color .15s ease, box-shadow .15s ease, background-color .15s ease;
	-webkit-appearance: none;
	appearance: none;
}
.dcf textarea { min-height: 150px; resize: vertical; }
.dcf input:hover, .dcf select:hover, .dcf textarea:hover { border-color: #A0AEC0; }
.dcf input:focus, .dcf select:focus, .dcf textarea:focus {
	outline: none;
	border-color: var(--dcf-primary);
	box-shadow: 0 0 0 3px rgba(43, 108, 176, .18);
}

.dcf-select { position: relative; }
.dcf-select::after {
	content: "";
	position: absolute;
	right: 16px;
	top: 50%;
	width: 8px;
	height: 8px;
	border-right: 2px solid var(--dcf-subtle);
	border-bottom: 2px solid var(--dcf-subtle);
	transform: translateY(-70%) rotate(45deg);
	pointer-events: none;
}
.dcf-select select { padding-right: 40px; cursor: pointer; }

.dcf-count { align-self: flex-end; color: var(--dcf-subtle); font-size: .8125rem; }

.dcf-check label {
	display: flex;
	align-items: flex-start;
	gap: 10px;
	color: var(--dcf-muted);
	font-size: .9375rem;
	font-weight: 400;
	cursor: pointer;
}
.dcf-check input {
	flex: none;
	width: 20px;
	height: 20px;
	margin: 2px 0 0;
	accent-color: var(--dcf-primary);
	cursor: pointer;
}
.dcf-check a { color: var(--dcf-primary); text-decoration: underline; }

.dcf-notice {
	margin: 0;
	padding: 14px 16px;
	background: var(--dcf-bg);
	border-left: 4px solid var(--dcf-primary);
	border-radius: 8px;
	color: var(--dcf-muted);
	font-size: .875rem;
	line-height: 1.55;
}

.dcf-hp { position: absolute !important; left: -9999px !important; width: 1px; height: 1px; overflow: hidden; }

.dcf-has-error input,
.dcf-has-error select,
.dcf-has-error textarea { border-color: var(--dcf-error); background: var(--dcf-error-bg); }
.dcf-error { color: var(--dcf-error); font-size: .875rem; font-weight: 500; }

.dcf-status:empty { display: none; }
.dcf-status-error {
	padding: 12px 14px;
	border-radius: 10px;
	background: var(--dcf-error-bg);
	border: 1px solid #FEB2B2;
	color: var(--dcf-error);
	font-size: .9375rem;
}

.dcf-submit {
	align-self: flex-start;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 10px;
	min-height: 48px;
	padding: 12px 32px;
	border: 0;
	border-radius: 999px;
	background: var(--dcf-primary);
	color: #fff;
	font: inherit;
	font-size: 1rem;
	font-weight: 600;
	cursor: pointer;
	transition: background-color .15s ease, transform .15s ease, box-shadow .15s ease;
	box-shadow: 0 4px 12px rgba(43, 108, 176, .25);
}
.dcf-submit:hover { background: var(--dcf-primary-dark); transform: translateY(-1px); }
.dcf-submit:focus-visible { outline: 3px solid rgba(43, 108, 176, .35); outline-offset: 3px; }
.dcf-submit:disabled { opacity: .7; cursor: default; transform: none; }

.dcf-spinner {
	display: none;
	width: 16px;
	height: 16px;
	border: 2px solid rgba(255, 255, 255, .4);
	border-top-color: #fff;
	border-radius: 50%;
	animation: dcf-spin .7s linear infinite;
}
.dcf-busy .dcf-spinner { display: inline-block; }
@keyframes dcf-spin { to { transform: rotate(360deg); } }

.dcf .dcf-form[hidden] { display: none !important; }

.dcf .dcf-success {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	text-align: center;
	padding: 24px 8px;
	outline: none;
}
.dcf .dcf-success[hidden] { display: none !important; }
.dcf-success-icon {
	display: inline-grid;
	place-items: center;
	width: 56px;
	height: 56px;
	margin-bottom: 12px;
	border-radius: 50%;
	background: #EBF4FF;
	color: var(--dcf-primary);
}
.dcf .dcf-success h3 {
	width: 100%;
	margin: 0 0 8px;
	text-align: center;
	color: var(--dcf-heading);
	font-size: 1.375rem;
}
.dcf .dcf-success p,
.dcf .dcf-success .dcf-success-text {
	width: 100%;
	max-width: 480px;
	margin: 0 auto !important;
	padding: 0;
	text-align: center !important;
	color: var(--dcf-muted);
}

@media (max-width: 600px) {
	.dcf { border-radius: 12px; }
	.dcf-row { grid-template-columns: 1fr; }
	.dcf-submit { width: 100%; align-self: stretch; }
}

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