/*
 * Online Donations — donation form styles.
 * Scoped under .od-donation-form-wrap / .od-payment-status. Deliberately
 * does NOT restyle <input>/<textarea>/<select>/<label> — most current block
 * themes already style form fields and labels globally, and re-declaring
 * color/border/radius/padding here would only fight that. This file handles
 * layout, spacing, and the handful of donation-specific elements (amount
 * presets, the card wrapper, section titles, status messages) that no
 * theme provides out of the box. Where a value should follow the active
 * theme, it reads the theme's own CSS custom properties with a plain
 * fallback, so the design still holds up on a theme that doesn't define them.
 */

.od-donation-form-wrap {
	max-width: 1120px;
	/* margin-top: 50px; */
	padding: 0px;
}
.od-donation-box{
	background-color: transparent;
	/* border: 1px solid #d8d8d8; */
	border-radius: 20px;
    box-shadow: 0 3px 16px 1px rgba(0, 0, 0, 0.15);
    padding: 40px;
}
.od-donation-form-wrap h2 {
	margin: 0;
	padding: 20px 0;
	font-size: 60px;
}

.od-form-section-title {
	font-size: 22px;
	color: #023991;
	/* background: #0239910a; */
	/* text-align: center; */
	margin-bottom: 0px;
	/* padding: 10px; */
	margin: 0px;
	display: flex;
	align-items: center;
	gap: 15px;
}
.od-form-section-title .step-number{
	background-color: #023991;
	width: 40px;
	height: 40px;
	border-radius: 50%;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 16px;
	color: #fff;
}
.od-form-section-title:first-of-type {
	margin-top: 0;
}

.od-currency-note {
	margin: 0 0 var(--wp--preset--spacing--20, 1em);
	font-size: var(--wp--preset--font-size--small, 0.85em);
	font-style: italic;
	opacity: 0.75;
}

.od-donation-form .od-field {
	margin-bottom: 25px;
}

.od-donation-form .od-field-group {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 0 var(--wp--preset--spacing--20, 1em);
}

.od-donation-form .od-field-group-card-meta {
	grid-template-columns: repeat(3, 1fr);
}

.od-donation-form .od-field-group-donation {
	grid-template-columns: auto 1fr;
	align-items: start;
}

.od-required {
	color: var(--wp--preset--color--vivid-red, #cc1818);
}

.od-field-label {
	display: block;
	margin-bottom: 0.6em;
	font-weight: 600;
}

.od-currency-options {
	display: flex;
	flex-wrap: wrap;
	gap: 0.75em;
}

.od-currency-option {
	position: relative;
}

.od-currency-option input {
	position: absolute;
	width: 1px;
	height: 1px;
	overflow: hidden;
	clip: rect(0 0 0 0);
	white-space: nowrap;
}

.od-currency-option label {
	display: inline-block;
	padding: 0.6em 1.25em;
	background-color: var(--wp--custom--input-background, #fff);
	border: 2px solid #d8d8d8;
	border-radius: 8px;
	color: currentColor;
	font-size: 1.05em;
	font-weight: 600;
	text-align: center;
	cursor: pointer;
	transition: background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.od-currency-option label:hover {
	background-color: color-mix(in srgb, var(--wp--preset--color--primary, #023991) 10%, transparent);
}

.od-currency-option input:checked + label {
	background-color: var(--wp--preset--color--primary, #023991);
	border-color: var(--wp--preset--color--primary, #023991);
	color: #fff;
}

.od-currency-option input:focus-visible + label {
	outline: 2px solid var(--wp--preset--color--primary, #023991);
	outline-offset: 2px;
}

/* Preset donation-amount buttons */
.od-amount-preset-buttons {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
	gap: 0.75em;
}

.od-amount-preset {
	padding: 0.75em 1em;
	background-color: var(--wp--custom--input-background, #fff);
	border: 2px solid #d8d8d8;
	border-radius: 8px;
	color: currentColor;
	font-size: 1.05em;
	font-weight: 600;
	text-align: center;
	cursor: pointer;
	transition: background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.od-amount-preset:hover {
	background-color: color-mix(in srgb, var(--wp--preset--color--primary, #023991) 10%, transparent);
}

.od-amount-preset.od-amount-preset-selected {
	background-color: var(--wp--preset--color--primary, #023991);
	border-color: var(--wp--preset--color--primary, #023991);
	color: #fff;
}

.od-amount-presets.od-invalid .od-amount-preset {
	border-color: var(--wp--preset--color--vivid-red, #cc1818);
}

.od-amount-input-wrap {
	position: relative;
}

/*
 * A filled "prefix chip" rather than plain floating text — its own
 * background covers the input's own left padding area completely, so it
 * can never visually collide/overlap with the placeholder or typed value
 * even if a theme's own input padding fights with ours.
 */
.od-amount-input-currency {
	position: absolute;
	top: 1px;
	bottom: 1px;
	left: 1px;
	display: flex;
	align-items: center;
	justify-content: center;
	min-width: 3.5em;
	padding: 0 0.75em;
	background-color: var(--wp--preset--color--theme-2, #f2f2f2);
	border-right: 1px solid #d8d8d8;
	border-radius: 5px 0 0 5px;
	font-size: 0.85em;
	font-weight: 700;
	letter-spacing: 0.02em;
	color: currentColor;
	pointer-events: none;
}

.od-donation-form .od-amount-input-wrap input {
	width: 100%;
	box-sizing: border-box;
	padding-left: 4.75em !important;
}

.od-convenience-charge-summary:not([hidden]) {
	display: block;
	margin: -10px 0 25px;
	padding: 12px 16px;
	border: 1px solid #0239911f;
	border-radius: 10px;
	background: #0239910a;
}

.od-convenience-charge-row {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 1em;
	font-size: var(--wp--preset--font-size--small, 0.9em);
}

.od-convenience-charge-row + .od-convenience-charge-row {
	margin-top: 8px;
	padding-top: 8px;
	border-top: 1px solid #0239911f;
}

.od-convenience-charge-total-row {
	color: #023991;
	font-size: 1em;
}

/*
 * Honeypot field — moved off-screen rather than display:none/visibility:
 * hidden, since simple bots specifically check for and skip those.
 */
.od-hp-field {
	position: absolute;
	left: -9999px;
	top: -9999px;
	height: 0;
	width: 0;
	overflow: hidden;
}

/*
 * Card type badges. Plain text stand-ins for real card-brand logos.
 * Positioned inside the Card Number field's own box (right-aligned) rather
 * than pushing the field width around as it appears/disappears.
 */
.od-card-number-wrap {
	position: relative;
}

.od-card-number-wrap input {
	padding-right: 4.5em;
}

.od-card-type-icon {
	position: absolute;
	top: 50%;
	right: 0.75em;
	transform: translateY(-50%);
	pointer-events: none;
}

.od-card-icon {
	display: inline-block;
	padding: 0.15em 0.5em;
	border-radius: 4px;
	font-size: 0.7rem;
	font-weight: 700;
	letter-spacing: 0.02em;
	color: #fff;
	white-space: nowrap;
}

.od-card-icon-visa {
	background-color: #1a1f71;
}

.od-card-icon-mastercard {
	background-color: #eb001b;
}

.od-card-icon-amex {
	background-color: #2e77bc;
}

.od-card-icon-discover {
	background-color: #ff6000;
}

/*
 * Select pickers (Expiry Month/Year). Matches the same visual language
 * (background/border/radius/sizing) a theme uses for its inputs, then adds
 * a custom dropdown arrow drawn with a bordered pseudo-element so its color
 * always tracks `currentColor` — no separate light/dark arrow asset needed.
 */
.od-select {
	position: relative;
	display: block;
}

.od-donation-form .od-select select {
	appearance: none;
	-webkit-appearance: none;
	-moz-appearance: none;
	width: 100%;
	box-sizing: border-box;
	background-color: var(--wp--custom--input-background, var(--wp--preset--color--theme-1, #fff));
	border: 1px solid currentColor;
	border-radius: 6px;
	box-shadow: none;
	color: currentColor;
	cursor: pointer;
	font-family: inherit;
	font-size: var(--wp--preset--font-size--small, 0.9rem);
	font-weight: inherit;
	line-height: 1.5;
	min-height: 42px;
	padding: 0.8rem 2.25rem 0.8rem 1rem;
}

.od-select::after {
	content: '';
	position: absolute;
	top: 50%;
	right: 1rem;
	width: 0;
	height: 0;
	margin-top: -3px;
	border-left: 5px solid transparent;
	border-right: 5px solid transparent;
	border-top: 6px solid currentColor;
	pointer-events: none;
}

.od-donation-form .od-select select:focus {
	outline: 1px solid currentColor;
}

.od-donation-form .od-select select:disabled {
	cursor: not-allowed;
	opacity: 0.6;
}

.od-donation-form input.od-invalid,
.od-donation-form select.od-invalid,
.od-donation-form textarea.od-invalid {
	border-color: var(--wp--preset--color--vivid-red, #cc1818);
}

.od-field-error {
	margin-top: 0.35em;
	color: var(--wp--preset--color--vivid-red, #cc1818);
	font-size: var(--wp--preset--font-size--small, 0.85em);
}

.od-donation-form-messages {
	margin-bottom: var(--wp--preset--spacing--20, 1em);
	padding: 0.75em 1em;
	border-radius: 6px;
	font-size: var(--wp--preset--font-size--small, 0.9em);
}

.od-donation-form-messages.od-message-error {
	background-color: color-mix(in srgb, var(--wp--preset--color--vivid-red, #cc1818) 12%, transparent);
	color: var(--wp--preset--color--vivid-red, #cc1818);
}

.od-donation-form-messages.od-message-success {
	background-color: color-mix(in srgb, #2e7d32 12%, transparent);
	color: #2e7d32;
}

/*
 * reCAPTCHA (left) and the Submit button (right) share one row, both
 * anchored to the same vertical center. `margin-left: auto` on the submit
 * field pushes it to the row's right edge whether or not reCAPTCHA is
 * present alongside it.
 */
.od-form-footer {
	display: flex;
	align-items: center;
	flex-wrap: wrap;
	gap: var(--wp--preset--spacing--20, 1em);
	margin-top: var(--wp--preset--spacing--30, 1.5em);
}

.od-field-recaptcha {
	max-width: 100%;
	overflow-x: auto;
}

.od-field-recaptcha .g-recaptcha {
	display: inline-block;
}

.od-field-submit {
	margin-left: auto;
}

.od-submit-button {
	width: auto;
	text-align: center;
	cursor: pointer;
}

.od-submit-button[disabled] {
	opacity: 0.6;
	cursor: not-allowed;
}

/* Payment status pages */

.od-payment-status {
	max-width: 640px;
	margin: var(--wp--preset--spacing--40, 2em) auto;
	padding: var(--wp--preset--spacing--40, 2em);
	text-align: center;
	border-radius: 8px;
}

.od-payment-status-success {
	background-color: color-mix(in srgb, #2e7d32 10%, transparent);
}

.od-payment-status-failed {
	background-color: color-mix(in srgb, var(--wp--preset--color--vivid-red, #cc1818) 10%, transparent);
}

.od-payment-status-pending,
.od-payment-status-unknown {
	background-color: var(--wp--preset--color--theme-2, #f2f2f2);
}

.od-payment-summary {
	max-width: 360px;
	margin: var(--wp--preset--spacing--20, 1em) auto;
	text-align: left;
}

.od-payment-summary dt {
	font-weight: 600;
}

.od-payment-summary dd {
	margin: 0 0 0.75em;
}

.od-donation-form-wrap input,
.od-donation-form-wrap textarea,
.od-donation-form-wrap select {
	border: 1px solid #d8d8d8 !important;
}

.form-inner-wrapper {
	padding: 15px 0px 15px 55px;
	border-bottom: 1px solid #d8d8d8;
	margin-bottom: 40px;
}
.form-inner-wrapper.last-wrapper{
	padding-bottom: 0;
	margin-bottom: 0;
	border-bottom: 0;
}


@media (max-width: 1399px) {
	.od-donation-form-wrap h2 {
		font-size: 55px;
		padding: 40px 0;
	}
}
@media (max-width: 1199px) {
	.od-donation-form-wrap h2 {
		font-size: 50px;
	}
}

@media (max-width: 991px) {
	.od-donation-form-wrap h2 {
		font-size: 45px;
		padding: 30px 0;
	}
}

@media (max-width: 767px) {
	.od-donation-form-wrap h2 {
		font-size: 35px;
	}
	.od-form-footer {
		flex-direction: column;
		justify-content: flex-start;
		align-items: flex-start;
	}
	.od-field-submit {
		margin-left: unset;
	}
}

@media (max-width: 575px) {
	.od-donation-box{
		padding: 20px;
	}
	.od-donation-form-wrap h2 {
		font-size: 26px;
	}
	.od-donation-form .od-field-group {
		grid-template-columns: 1fr;
	}
}
@media (max-width: 420px) {
	.od-donation-form-wrap .g-recaptcha {
		transform-origin: 0;
		transform: scale(.87);
	}
	.od-donation-form-wrap .od-field-recaptcha {
		overflow: unset;
	}
	.od-donation-form-wrap h2 {
		padding: 25px 0;
	}
	.form-inner-wrapper {
		padding: 25px 25px 0px 25px;
	}
}
@media (max-width: 360px) {
	.od-donation-form-wrap .g-recaptcha {
		transform-origin: 0;
		transform: scale(.7);
	}
}

.od-payment-status-success h1 {
	font-size: 60px;
	margin-bottom: 0;
}

.od-payment-status-success p {
	font-size: 28px;
	font-weight: 700;
}

.od-payment-status-success p a {
	font-size: 16px;
	text-decoration: none;
}
