/* Chaps Forms — matches the CHAPS Fragrances site design */
.chaps-form-wrap {
	--cf-primary: #233D8D;
	--cf-dark: #111B3F;
	--cf-text: #525B70;
	--cf-accent: #E92544;
	--cf-border: #D9DDE8;
	--cf-bg: #FFFFFF;
	--cf-soft: #F4F5F9;
	--cf-gap: 24px;
	width: 100%;
	font-family: "Montserrat", "Helvetica Neue", Arial, sans-serif;
}

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

.chaps-form .cf-fields {
	display: flex;
	flex-wrap: wrap;
	margin: 0 calc(var(--cf-gap) / -2);
	row-gap: var(--cf-gap);
}

.chaps-form .cf-field {
	padding: 0 calc(var(--cf-gap) / 2);
	display: flex;
	flex-direction: column;
	position: relative;
	margin: 0;
}

.chaps-form .cf-w-100 { width: 100%; }
.chaps-form .cf-w-66  { width: 66.666%; }
.chaps-form .cf-w-50  { width: 50%; }
.chaps-form .cf-w-33  { width: 33.333%; }

.chaps-form .cf-label {
	display: block;
	margin: 0 0 9px;
	color: var(--cf-dark);
	font-family: inherit;
	font-size: 12px;
	font-weight: 500;
	line-height: 1.4;
	letter-spacing: 0;
}

.chaps-form.cf-mark-required .cf-required > .cf-label::after,
.chaps-form.cf-mark-required .cf-required .cf-check-text::after {
	content: "*";
	color: var(--cf-accent);
	padding-inline-start: .2em;
}

.chaps-form.cf-no-labels .cf-field:not(.cf-type-acceptance):not(.cf-type-checkbox):not(.cf-type-radio) > .cf-label {
	position: absolute !important;
	width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0);
}

.chaps-form input[type="text"],
.chaps-form input[type="email"],
.chaps-form input[type="tel"],
.chaps-form input[type="number"],
.chaps-form input[type="url"],
.chaps-form input[type="date"],
.chaps-form select,
.chaps-form textarea {
	width: 100%;
	min-height: 47px;
	margin: 0;
	padding: 12px 16px;
	color: var(--cf-dark);
	background-color: var(--cf-bg);
	border: 1px solid var(--cf-border);
	border-radius: 0;
	box-shadow: none;
	font-family: inherit;
	font-size: 15px;
	font-weight: 400;
	line-height: 1.5;
	outline: none;
	transition: border-color .25s ease, box-shadow .25s ease;
	-webkit-appearance: none;
	appearance: none;
}

.chaps-form textarea { resize: vertical; min-height: 130px; }

.chaps-form input::placeholder,
.chaps-form textarea::placeholder { color: #8A91A3; opacity: 1; }

.chaps-form input:focus,
.chaps-form select:focus,
.chaps-form textarea:focus {
	border-color: var(--cf-primary);
	box-shadow: 0 0 0 3px rgba(35, 61, 141, .10);
}

.chaps-form .cf-select-wrap { position: relative; }
.chaps-form .cf-select-wrap::after {
	content: "";
	position: absolute;
	right: 18px;
	top: 50%;
	width: 8px;
	height: 8px;
	margin-top: -6px;
	border-right: 1.5px solid var(--cf-dark);
	border-bottom: 1.5px solid var(--cf-dark);
	transform: rotate(45deg);
	pointer-events: none;
}
.chaps-form select { padding-right: 44px; cursor: pointer; }
.chaps-form select:invalid,
.chaps-form select.cf-placeholder { color: #8A91A3; }
.chaps-form select option { color: var(--cf-dark); }

/* Checkbox / radio / acceptance */
.chaps-form .cf-options { display: flex; flex-wrap: wrap; gap: 10px 24px; }
.chaps-form .cf-check-label {
	display: inline-flex;
	align-items: flex-start;
	gap: 10px;
	cursor: pointer;
	color: var(--cf-text);
	font-size: 14px;
	line-height: 1.5;
}
.chaps-form .cf-check-label input {
	flex: 0 0 auto;
	width: 18px;
	height: 18px;
	margin: 1px 0 0;
	border: 1px solid var(--cf-border);
	background: var(--cf-bg);
	border-radius: 0;
	-webkit-appearance: none;
	appearance: none;
	cursor: pointer;
	position: relative;
	transition: background-color .2s ease, border-color .2s ease;
}
.chaps-form .cf-check-label input[type="radio"] { border-radius: 50%; }
.chaps-form .cf-check-label input:checked {
	background: var(--cf-primary);
	border-color: var(--cf-primary);
}
.chaps-form .cf-check-label input[type="checkbox"]:checked::after {
	content: "";
	position: absolute;
	left: 5px;
	top: 1px;
	width: 5px;
	height: 10px;
	border: solid #fff;
	border-width: 0 2px 2px 0;
	transform: rotate(45deg);
}
.chaps-form .cf-check-label input[type="radio"]:checked::after {
	content: "";
	position: absolute;
	inset: 4px;
	border-radius: 50%;
	background: #fff;
}
.chaps-form .cf-check-label input:focus-visible { box-shadow: 0 0 0 3px rgba(35, 61, 141, .18); }
.chaps-form .cf-check-text a { color: var(--cf-primary); }

.chaps-form .cf-heading h4 {
	margin: 8px 0 0;
	color: var(--cf-dark);
	font-size: 12px;
	font-weight: 600;
	letter-spacing: 1.4px;
	text-transform: uppercase;
}

/* Submit button */
.chaps-form .cf-submit {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 10px;
	width: 100%;
	padding: 20px;
	margin: 0;
	color: #FFFFFF;
	background-color: var(--cf-primary);
	border: 0;
	border-radius: 0;
	font-family: inherit;
	font-size: 12px;
	font-weight: 600;
	letter-spacing: 1.4px;
	line-height: 1.2;
	text-transform: uppercase;
	white-space: pre;
	cursor: pointer;
	transition: background-color .3s ease, color .3s ease;
}
.chaps-form .cf-submit:hover,
.chaps-form .cf-submit:focus-visible {
	color: #FFFFFF;
	background-color: var(--cf-dark);
}
.chaps-form .cf-submit[disabled] { opacity: .75; cursor: wait; }

.chaps-form .cf-spinner {
	display: none;
	width: 14px;
	height: 14px;
	border: 2px solid rgba(255, 255, 255, .35);
	border-top-color: #fff;
	border-radius: 50%;
	animation: cf-spin .8s linear infinite;
}
.chaps-form.cf-loading .cf-spinner { display: inline-block; }
@keyframes cf-spin { to { transform: rotate(360deg); } }

/* Errors + messages */
.chaps-form .cf-error {
	display: none;
	margin-top: 6px;
	color: var(--cf-accent);
	font-size: 12px;
	line-height: 1.4;
}
.chaps-form .cf-invalid .cf-error { display: block; }
.chaps-form .cf-invalid input,
.chaps-form .cf-invalid select,
.chaps-form .cf-invalid textarea { border-color: var(--cf-accent); }
.chaps-form .cf-invalid .cf-check-label input { border-color: var(--cf-accent); }

.chaps-form .cf-message {
	display: none;
	margin-top: 20px;
	font-size: 14px;
	line-height: 1.6;
}
.chaps-form .cf-message.cf-show { display: block; }
.chaps-form .cf-message.cf-success {
	color: var(--cf-primary);
	padding: 16px 18px;
	background: var(--cf-soft);
	border-left: 3px solid var(--cf-primary);
}
.chaps-form .cf-message.cf-fail {
	color: var(--cf-accent);
	padding: 16px 18px;
	background: #FDF1F3;
	border-left: 3px solid var(--cf-accent);
}

/* Honeypot */
.chaps-form .cf-hp {
	position: absolute !important;
	left: -9999px !important;
	width: 1px !important;
	height: 1px !important;
	overflow: hidden !important;
}

.chaps-form-missing { color: #E92544; font-size: 13px; }

/* Responsive */
@media (max-width: 1024px) {
	.chaps-form .cf-w-33,
	.chaps-form .cf-w-66 { width: 50%; }
}
@media (max-width: 767px) {
	.chaps-form .cf-w-33,
	.chaps-form .cf-w-50,
	.chaps-form .cf-w-66 { width: 100%; }
	.chaps-form-wrap { --cf-gap: 20px; }
}
