/**
 * Public registration form.
 *
 * Deliberately restrained: inherits the theme's fonts and colours so it sits
 * inside an Elementor-designed page without fighting it.
 */

.oa-register {
	margin: 2em 0;
	padding: 1.5em;
	border: 1px solid rgba( 0, 0, 0, 0.12 );
	border-radius: 6px;
}

.oa-register__title {
	margin: 0 0 1em;
}

.oa-register__error {
	margin: 0 0 1em;
	padding: 0.75em 1em;
	border-left: 4px solid #d63638;
	background: rgba( 214, 54, 56, 0.06 );
}

.oa-register__options {
	margin: 0 0 1.5em;
	padding: 0;
	border: 0;
}

.oa-register__options legend,
.oa-register__pay legend {
	margin-bottom: 0.5em;
	padding: 0;
	font-weight: 600;
}

.oa-register__option {
	display: flex;
	gap: 0.75em;
	align-items: flex-start;
	margin-bottom: 0.5em;
	padding: 0.85em 1em;
	border: 1px solid rgba( 0, 0, 0, 0.12 );
	border-radius: 4px;
	cursor: pointer;
}

.oa-register__option:hover {
	border-color: rgba( 0, 0, 0, 0.3 );
}

/* A full option stays visible — it tells people what they missed. */
.oa-register__option.is-full {
	opacity: 0.55;
	cursor: not-allowed;
}

.oa-register__option-body {
	display: flex;
	flex: 1;
	flex-direction: column;
	gap: 0.15em;
}

.oa-register__option-name {
	font-weight: 600;
}

.oa-register__option-desc {
	font-size: 0.9em;
	opacity: 0.8;
}

.oa-register__option-price {
	font-variant-numeric: tabular-nums;
}

.oa-register__option-price small {
	margin-left: 0.5em;
	opacity: 0.75;
}

.oa-register__field {
	display: flex;
	flex-direction: column;
	gap: 0.35em;
	margin-bottom: 1.25em;
}

.oa-register__field label {
	font-weight: 600;
}

/*
 * Text inputs only. A checkbox or radio stretched to width:100% renders as a
 * lone box floating in the middle of the row, which is what made the agreement
 * question look broken.
 */
.oa-register__field input:not( [type="checkbox"] ):not( [type="radio"] ),
.oa-register__field textarea {
	width: 100%;
	padding: 0.6em 0.75em;
	border: 1px solid rgba( 0, 0, 0, 0.25 );
	border-radius: 4px;
	font: inherit;
}

/* --- Checkbox question: box and text on one line --- */

.oa-register__field--check {
	margin: 1.1em 0;
}

.oa-register .oa-register__check {
	display: flex;
	align-items: flex-start;
	gap: 0.6em;
	/* Overrides the bold block label styling above; this reads as a sentence. */
	font-weight: 400;
	line-height: 1.45;
	cursor: pointer;
}

.oa-register__check input[type="checkbox"] {
	flex: 0 0 auto;
	width: 1.1em;
	height: 1.1em;
	/* Nudged down so the box aligns with the first line of text, not its top. */
	margin-top: 0.18em;
}

.oa-register__check-text {
	min-width: 0;
}

.oa-register__help {
	font-size: 0.85em;
	opacity: 0.75;
}

.oa-register__pay {
	margin: 0 0 1.5em;
	padding: 1em;
	border: 1px solid rgba( 0, 0, 0, 0.12 );
	border-radius: 4px;
}

.oa-register__pay label {
	display: block;
	margin-bottom: 0.4em;
	cursor: pointer;
}

.oa-register__submit {
	padding: 0.8em 1.6em;
	border: 0;
	border-radius: 4px;
	background: #1e1e1e;
	color: #fff;
	font: inherit;
	font-weight: 600;
	cursor: pointer;
}

/*
 * Elementor's kit styles `button:hover` (background-color, colour,
 * border-radius) at specificity (0,2,1), and its base `button` rule at (0,1,1)
 * already outranked the single-class rule above. Scoping to the form wrapper
 * and wrapping the states in :is() reaches (0,3,0), which wins in both cases,
 * so this button looks the same regardless of the theme's button settings.
 */
.oa-register .oa-register__submit,
.oa-register .oa-register__submit:is( :hover, :focus, :focus-visible, :active ) {
	padding: 0.8em 1.6em;
	border: 0;
	border-radius: 4px;
	background: var( --oa-submit-bg, #1e1e1e );
	color: var( --oa-submit-text, #fff );
	font-family: inherit;
	font-size: inherit;
	font-weight: 600;
	line-height: 1.2;
	letter-spacing: normal;
	text-decoration: none;
	cursor: pointer;
}

.oa-register .oa-register__submit:is( :hover, :focus, :focus-visible ) {
	background: var( --oa-submit-bg-hover, #000 );
}

.oa-register .oa-register__submit:focus-visible {
	outline: 2px solid currentColor;
	outline-offset: 3px;
}

/* A finished event says so rather than leaving a gap. */
.oa-register--closed {
	text-align: center;
	opacity: 0.8;
}

.oa-register--closed p {
	margin: 0;
}

/* First and last name side by side, stacking on narrow screens. */
.oa-register__row {
	display: grid;
	grid-template-columns: repeat( auto-fit, minmax( 200px, 1fr ) );
	gap: 0 1.25em;
}

/*
 * Honeypot. Positioned off-screen rather than display:none — a bot that parses
 * the stylesheet is likelier to skip a hidden field than an off-screen one, and
 * aria-hidden on the wrapper keeps it out of the accessibility tree either way.
 */
.oa-register .oa-hp {
	position: absolute;
	left: -9999px;
	width: 1px;
	height: 1px;
	overflow: hidden;
}

.oa-register .oa-captcha {
	margin: 1.25rem 0;
}

/* --- Amount due, above the submit button --- */

.oa-register__total {
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	gap: 0.35em 0.75em;
	margin: 1.75em 0 1.25em;
	padding: 1em 1.15em;
	border: 1px solid rgba( 0, 0, 0, 0.12 );
	border-radius: 6px;
	background: rgba( 0, 0, 0, 0.03 );
}

.oa-register__total-label {
	font-weight: 600;
}

.oa-register__total-amount {
	font-size: 1.5em;
	font-weight: 700;
	line-height: 1.1;
}

.oa-register__total-note {
	/* Takes the whole second line so the amount is never crowded. */
	flex: 1 0 100%;
	color: rgba( 0, 0, 0, 0.6 );
	font-size: 0.9em;
}
