.amber-form-card {
	--amber-form-red: #c4121a;
	--amber-form-navy: #17295d;
	--amber-form-text: #343b47;
	--amber-form-muted: #6f7782;
	--amber-form-line: #dfe3e8;
	width: min(1120px, calc(100% - 2rem));
	margin: clamp(2rem, 5vw, 4.5rem) auto;
	padding: clamp(1.4rem, 4vw, 3.25rem);
	border: 1px solid rgb(23 41 93 / 8%);
	border-top: 5px solid var(--amber-form-red);
	border-radius: 18px;
	background: #fff;
	box-shadow: 0 18px 55px rgb(31 43 72 / 9%);
	color: var(--amber-form-text);
}

.amber-form-card__heading {
	margin-bottom: clamp(1.6rem, 4vw, 2.6rem);
}

.amber-form-card__eyebrow {
	margin: 0 0 0.35rem;
	color: var(--amber-form-navy);
	font-size: 0.75rem;
	font-weight: 800;
	letter-spacing: 0.14em;
	text-transform: uppercase;
}

.amber-form-card__heading h2 {
	margin: 0;
	color: var(--amber-form-red);
	font-size: clamp(1.7rem, 3.5vw, 2.55rem);
	font-weight: 750;
	line-height: 1.25;
}

.amber-form-card__heading > span {
	display: block;
	width: 62px;
	height: 3px;
	margin-top: 0.85rem;
	border-radius: 999px;
	background: var(--amber-form-red);
}

.amber-form-card .amber-registration-form {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 1.35rem 1.5rem;
	max-width: none;
}

.amber-form-field,
.amber-form-actions,
.amber-form-section {
	min-width: 0;
}

.amber-form-field--full,
.amber-form-section,
.amber-form-actions,
.amber-form-card .amber-registration-notice {
	grid-column: 1 / -1;
}

.amber-form-label,
.amber-form-field > label:not(.amber-form-consent) {
	display: block;
	margin-bottom: 0.48rem;
	color: var(--amber-form-navy);
	font-size: 0.96rem;
	font-weight: 700;
	line-height: 1.5;
}

.amber-form-label b,
.amber-form-field--privacy b,
.amber-form-consent b {
	color: var(--amber-form-red);
}

.amber-form-help {
	margin: -0.28rem 0 0.55rem;
	color: var(--amber-form-muted);
	font-size: 0.84rem;
	line-height: 1.55;
}

.amber-form-card .amber-registration-form :is(input:not([type="checkbox"]):not([type="radio"]), select, textarea) {
	box-sizing: border-box;
	width: 100%;
	max-width: none;
	min-height: 50px;
	margin: 0;
	padding: 0.72rem 0.85rem;
	border: 1px solid var(--amber-form-line);
	border-radius: 7px;
	background: #fff;
	box-shadow: 0 1px 2px rgb(23 41 93 / 3%);
	color: var(--amber-form-text);
	font: inherit;
	transition: border-color 160ms ease, box-shadow 160ms ease;
}

.amber-form-card .amber-registration-form textarea {
	min-height: 125px;
	resize: vertical;
}

.amber-form-card .amber-registration-form :is(input, select, textarea):focus-visible {
	outline: 0;
	border-color: var(--amber-form-red);
	box-shadow: 0 0 0 3px rgb(196 18 26 / 12%);
}

.amber-form-field fieldset {
	min-width: 0;
	margin: 0;
	padding: 0;
	border: 0;
}

.amber-form-field legend {
	width: 100%;
	padding: 0;
}

.amber-form-options {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 0.65rem 0.9rem;
}

.amber-form-options label,
.amber-form-consent,
.amber-form-field--privacy label {
	display: flex;
	align-items: flex-start;
	gap: 0.62rem;
	min-height: 46px;
	box-sizing: border-box;
	margin: 0;
	padding: 0.72rem 0.85rem;
	border: 1px solid #e6e8ec;
	border-radius: 7px;
	background: #fafbfc;
	color: var(--amber-form-text);
	font-size: 0.92rem;
	line-height: 1.55;
	cursor: pointer;
}

.amber-form-options input,
.amber-form-consent input,
.amber-form-field--privacy input {
	flex: 0 0 auto;
	width: 18px;
	height: 18px;
	margin: 0.14rem 0 0;
	accent-color: var(--amber-form-red);
}

/* The legacy theme styles every non-checkbox input as a full-width text box. */
.amber-form-card .amber-registration-form .amber-form-options input[type="radio"] {
	box-sizing: border-box;
	flex: 0 0 18px;
	width: 18px;
	min-width: 18px;
	max-width: 18px;
	height: 18px;
	min-height: 18px;
	margin: 0.14rem 0 0;
	padding: 0;
	border-radius: 50%;
	box-shadow: none;
}

.amber-form-section {
	margin: 0.3rem 0 0;
	padding: 1.05rem 1.2rem;
	border-left: 4px solid var(--amber-form-red);
	border-radius: 0 8px 8px 0;
	background: linear-gradient(90deg, rgb(196 18 26 / 6%), rgb(196 18 26 / 1%));
}

.amber-form-section h3 {
	margin: 0;
	color: var(--amber-form-navy);
	font-size: clamp(1.15rem, 2vw, 1.4rem);
}

.amber-form-section p {
	margin: 0.35rem 0 0;
	color: var(--amber-form-muted);
	line-height: 1.65;
}

.amber-form-field--privacy {
	padding-top: 0.35rem;
	border-top: 1px solid #edf0f3;
}

.amber-form-actions {
	display: flex;
	justify-content: flex-start;
	padding-top: 0.2rem;
}

.amber-form-card .amber-registration-form button {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 0.8rem;
	min-width: 165px;
	min-height: 50px;
	padding: 0.75rem 1.35rem;
	border: 0;
	border-radius: 6px;
	background: linear-gradient(180deg, #d9272f, #b40911);
	box-shadow: 0 8px 20px rgb(196 18 26 / 22%);
	color: #fff;
	font: inherit;
	font-weight: 750;
	cursor: pointer;
}

.amber-form-card .amber-registration-form button:hover,
.amber-form-card .amber-registration-form button:focus-visible {
	background: #9f0810;
	color: #fff;
}

.amber-form-card .amber-registration-notice {
	margin: 0 0 1.25rem;
	padding: 0.85rem 1rem;
	border: 1px solid #b8dec1;
	border-left: 4px solid #27823b;
	border-radius: 6px;
	background: #f2fbf4;
}

.amber-form-card .amber-registration-notice p {
	margin: 0;
}

.amber-form-card .amber-registration-error {
	border-color: #efc0c0;
	border-left-color: var(--amber-form-red);
	background: #fff5f5;
}

@media (max-width: 760px) {
	.amber-form-card {
		width: min(100% - 1rem, 1120px);
		padding: 1.25rem 1rem 1.5rem;
		border-radius: 12px;
	}

	.amber-form-card .amber-registration-form,
	.amber-form-options {
		grid-template-columns: 1fr;
	}

	.amber-form-field,
	.amber-form-field--half {
		grid-column: 1 / -1;
	}

	.amber-form-actions button {
		width: 100%;
	}
}

@media (prefers-reduced-motion: reduce) {
	.amber-form-card * {
		scroll-behavior: auto !important;
		transition: none !important;
	}
}
