/**
 * ABF sponsored pass application — /free-pass/.
 *
 * Loads after pay.css and borrows its tokens, panels, button and order rail, so
 * the claim form is the same surface as the checkout rather than a new one. Only
 * what pay.css has no answer for lives here: text inputs on the DARK panel (the
 * checkout's coupon field is a light input from an older pass) and a checkbox.
 *
 * Contrast on the panel ground #0A0410:
 *   #D6CDE2 label 12.6:1 · #A79FB8 hint 7.99:1 · #FFB3C4 error 11.4:1
 *   input border rgba(255,255,255,.28) ≈ #4E4855, 3.1:1 against the panel — meets
 *   the 3:1 non-text minimum for a control boundary.
 */

.abf-pay.abf-claim {
	max-width: 1040px;
}

.abf-pay .abf-claim__field {
	margin: 0 0 18px;
}

.abf-pay .abf-claim__label {
	display: block;
	margin: 0 0 7px;
	font-size: 13px;
	font-weight: 600;
	color: #d6cde2;
}

.abf-pay .abf-claim__input,
.abf-pay.abf-claim .abf-pay__phone .abf-phone__code,
.abf-pay.abf-claim .abf-pay__phone .abf-phone__number {
	width: 100%;
	height: 48px;
	padding: 0 14px;
	border: 1px solid rgba( 255, 255, 255, 0.28 );
	border-radius: 10px;
	background: rgba( 255, 255, 255, 0.04 );
	color: var( --pay-ink );
	/* 16px stops iOS zooming the page on focus. */
	font-family: var( --pay-text );
	font-size: 16px;
	caret-color: var( --pay-gold );
	transition: border-color 160ms var( --pay-ease ), background-color 160ms var( --pay-ease );
}

.abf-pay.abf-claim .abf-pay__phone .abf-phone__code {
	width: auto;
}

.abf-pay .abf-claim__input:hover,
.abf-pay.abf-claim .abf-pay__phone .abf-phone__number:hover {
	border-color: rgba( 255, 255, 255, 0.44 );
}

.abf-pay .abf-claim__input:focus,
.abf-pay.abf-claim .abf-pay__phone .abf-phone__number:focus {
	outline: 2px solid var( --pay-gold );
	outline-offset: 1px;
	border-color: transparent;
	background: rgba( 255, 255, 255, 0.07 );
}

.abf-pay .abf-claim__input[aria-invalid="true"],
.abf-pay.abf-claim .abf-pay__phone .abf-phone__number[aria-invalid="true"] {
	border-color: #ff7a93;
}

/* Autofill paints its own pale yellow; keep the field on the dark ground. */
.abf-pay .abf-claim__input:-webkit-autofill {
	-webkit-text-fill-color: #ffffff;
	box-shadow: 0 0 0 1000px #1a1220 inset;
}

.abf-pay .abf-claim__hint {
	margin: 6px 0 0;
	font-size: 12px;
	line-height: 1.45;
	color: var( --pay-body );
}

/* Off-screen, not display:none — some bots skip fields they can tell are hidden. */
.abf-pay .abf-claim__trap {
	position: absolute;
	left: -10000px;
	width: 1px;
	height: 1px;
	overflow: hidden;
}

.abf-pay .abf-claim__check {
	display: flex;
	align-items: flex-start;
	gap: 12px;
	margin: 4px 0 18px;
	font-size: 14px;
	line-height: 1.5;
	color: var( --pay-body );
	cursor: pointer;
}

.abf-pay .abf-claim__check input {
	flex: 0 0 auto;
	width: 20px;
	height: 20px;
	margin: 1px 0 0;
	accent-color: var( --pay-gold );
	cursor: pointer;
}

.abf-pay .abf-claim__check input[aria-invalid="true"] {
	outline: 2px solid #ff7a93;
	outline-offset: 2px;
}

.abf-pay .abf-claim__submit {
	justify-content: center;
	width: 100%;
	margin-top: 4px;
	border-radius: 10px;
}

.abf-pay .abf-claim__submit[disabled] {
	cursor: default;
	transform: none;
	opacity: 0.75;
}

.abf-pay .abf-claim__submit.is-busy::before {
	content: "";
	width: 16px;
	height: 16px;
	border: 2px solid rgba( 10, 4, 16, 0.25 );
	border-top-color: #0a0410;
	border-radius: 999px;
	animation: abf-pay-spin 640ms linear infinite;
}

.abf-pay .abf-claim__form .abf-pay__error {
	margin: 0 0 16px;
}

/* The rail's figure is a word here, not a number. */
.abf-pay.abf-claim .abf-pay__price > span {
	color: #5fe0b0;
}

.abf-pay .abf-claim__closed {
	max-width: 640px;
}

@media ( max-width: 900px ) {
	/* Unlike checkout, the form is the task; the pass summary follows it. */
	.abf-pay.abf-claim .abf-pay__aside {
		order: 0;
	}
}

@media ( max-width: 560px ) {
	/* The rail stacks here; left-align the struck price with "Free" under it. */
	.abf-pay.abf-claim .abf-pay__price {
		align-items: flex-start;
	}
}

@media ( prefers-reduced-motion: reduce ) {
	.abf-pay .abf-claim__submit.is-busy::before {
		animation-duration: 1600ms;
	}
}

/* ---------------------------------------------- sponsored application --- */

/* The scarcity line under the lede. Gold is the site's own "limited offer"
   colour (the old early-bird chip); 14.75:1 on the page ground. */
.abf-pay .abf-claim__badge {
	display: inline-flex;
	align-items: center;
	gap: 10px;
	margin: -12px 0 30px;
	padding: 6px 14px 6px 6px;
	border: 1px solid rgba( 253, 219, 0, 0.4 );
	border-radius: 999px;
	background: rgba( 253, 219, 0, 0.08 );
	font-size: 13px;
	font-weight: 600;
	line-height: 1.3;
	color: var( --pay-gold );
}

.abf-pay .abf-claim__badge-n {
	display: inline-grid;
	place-items: center;
	min-width: 44px;
	height: 30px;
	padding: 0 10px;
	border-radius: 999px;
	background: var( --pay-gold );
	color: #0a0410;
	font-family: var( --pay-display );
	font-size: 16px;
	font-weight: 400;
	font-variant-numeric: tabular-nums;
}

.abf-pay .abf-claim__sponsor {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
	margin: 16px 0 0;
	padding: 16px 0 0;
	border-top: 1px solid var( --pay-line-soft );
	font-size: 12px;
	color: var( --pay-muted );
}

.abf-pay .abf-claim__sponsor img {
	display: block;
	width: 150px;
	max-width: 55%;
	height: auto;
}

.abf-pay .abf-claim__done[hidden],
.abf-pay .abf-claim__form[hidden] {
	display: none;
}

.abf-pay .abf-claim__done:focus {
	outline: none;
}

.abf-pay .abf-claim__done-mark {
	display: block;
	width: 48px;
	height: 48px;
	margin: 0 0 18px;
	color: #5fe0b0;
}

.abf-pay .abf-claim__done .abf-pay__body strong {
	color: var( --pay-ink );
	overflow-wrap: anywhere;
}

/* ------------------------------------------- full application (1.47.0) --- */

.abf-pay .abf-claim__group {
	min-width: 0;
	margin: 0 0 8px;
	padding: 0;
	border: 0;
}

.abf-pay .abf-claim__group + .abf-claim__group {
	margin-top: 10px;
	padding-top: 22px;
	border-top: 1px solid var( --pay-line-soft );
}

/* A legend sits ON the fieldset border by default; floating it makes it an
   ordinary block heading under the divider. */
.abf-pay .abf-claim__legend {
	float: left;
	width: 100%;
	margin: 0 0 16px;
	padding: 0;
	font-family: var( --pay-display );
	font-size: 17px;
	font-weight: 400;
	line-height: 1.3;
	color: var( --pay-ink );
}

.abf-pay .abf-claim__legend + * {
	clear: both;
}

/* Two short fields side by side on wide screens, stacked on phones. */
.abf-pay .abf-claim__row {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 0 14px;
}

.abf-pay .abf-claim__row > * {
	min-width: 0;
}

.abf-pay .abf-claim__opt {
	margin-left: 4px;
	font-weight: 400;
	color: var( --pay-muted );
}

/* Native select, drawn to match the inputs. The chevron is an inline SVG in
   the body ink, not a glyph. */
.abf-pay .abf-claim__select {
	appearance: none;
	-webkit-appearance: none;
	padding-right: 40px;
	background-image: url( "data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23A79FB8' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9.5 12 15.5 18 9.5'/%3E%3C/svg%3E" );
	background-repeat: no-repeat;
	background-position: right 14px center;
	background-size: 16px 16px;
	cursor: pointer;
	text-overflow: ellipsis;
}

/* Options render in the OS menu, which ignores the dark field: give them a
   readable pair of their own. */
.abf-pay .abf-claim__select option {
	background: #1a1220;
	color: #ffffff;
}

.abf-pay .abf-claim__textarea {
	height: auto;
	min-height: 112px;
	padding: 12px 14px;
	line-height: 1.5;
	resize: vertical;
}

.abf-pay .abf-claim__ticks {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 8px;
	margin-top: 2px;
}

.abf-pay .abf-claim__tick {
	display: flex;
	align-items: flex-start;
	gap: 10px;
	padding: 10px 12px;
	border: 1px solid var( --pay-line-soft );
	border-radius: 10px;
	background: rgba( 255, 255, 255, 0.02 );
	font-size: 14px;
	line-height: 1.35;
	color: var( --pay-body );
	cursor: pointer;
	transition: border-color 160ms var( --pay-ease ), background-color 160ms var( --pay-ease );
}

.abf-pay .abf-claim__tick:hover {
	border-color: rgba( 255, 255, 255, 0.3 );
}

.abf-pay .abf-claim__tick input {
	flex: 0 0 auto;
	width: 18px;
	height: 18px;
	margin: 0;
	accent-color: var( --pay-gold );
}

.abf-pay .abf-claim__tick:has( input:checked ) {
	border-color: rgba( 253, 219, 0, 0.5 );
	background: rgba( 253, 219, 0, 0.06 );
	color: var( --pay-ink );
}

.abf-pay .abf-claim__tick:has( input:focus-visible ) {
	outline: 2px solid var( --pay-gold );
	outline-offset: 2px;
}

.abf-pay .abf-claim__select[aria-invalid="true"],
.abf-pay .abf-claim__textarea[aria-invalid="true"] {
	border-color: #ff7a93;
}

@media ( max-width: 560px ) {
	.abf-pay .abf-claim__row,
	.abf-pay .abf-claim__ticks {
		grid-template-columns: 1fr;
	}
}
