/* Mollie Donation Form — inline step, popup modal, status cards */

/* ── Status card ── */
.mdf-status-card {
	display: flex;
	align-items: flex-start;
	gap: 20px;
	border: 2px solid;
	border-radius: 16px;
	padding: 24px 28px;
	margin-bottom: 28px;
	font-family: inherit;
}
.mdf-status-icon {
	flex-shrink: 0;
	width: 52px;
	height: 52px;
	border-radius: 50%;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 22px;
	font-weight: 700;
	color: #fff;
	line-height: 1;
}
.mdf-status-body { flex: 1; }
.mdf-status-title {
	margin: 0 0 8px;
	font-size: 20px;
	font-weight: 700;
	line-height: 1.2;
}
.mdf-status-message {
	margin: 0 0 18px;
	font-size: 15px;
	color: #444;
	line-height: 1.6;
}
.mdf-status-btn {
	display: inline-block;
	padding: 10px 24px;
	border-radius: 50px;
	color: #fff !important;
	font-size: 14px;
	font-weight: 600;
	text-decoration: none;
	letter-spacing: 0.5px;
	transition: opacity 0.15s;
}
.mdf-status-btn:hover { opacity: 0.85; text-decoration: none; }

/* ── Trigger button + amount step ── */
/* The shortcode renders only a button; the amount controls below now live
   inside the popup's amount step. */
.mollie-donation-wrap { font-family: inherit; }
.mollie-donation-presets {
	display: flex;
	gap: 8px;
	flex-wrap: wrap;
	margin-bottom: 12px;
}
.mollie-donation-preset {
	background: #fff;
	border: 2px solid #d0e8f0;
	border-radius: 50px;
	padding: 8px 20px;
	cursor: pointer;
	font-size: 15px;
	color: #1a2e4a;
	transition: background 0.15s, border-color 0.15s;
}
.mollie-donation-preset:hover,
.mollie-donation-preset.active {
	background: #d0e8f0;
	border-color: #a0c8dc;
}
.mollie-donation-row {
	display: flex;
	gap: 12px;
	align-items: center;
	flex-wrap: wrap;
}
.mollie-donation-input-wrap {
	display: flex;
	align-items: center;
	background: #fff;
	border: 2px solid #d0e8f0;
	border-radius: 50px;
	padding: 0 20px;
	flex: 1;
	min-width: 160px;
}
.mollie-donation-euro {
	font-size: 18px;
	color: #1a2e4a;
	margin-right: 8px;
	user-select: none;
}
.mollie-donation-input {
	border: none;
	outline: none;
	font-size: 18px;
	color: #1a2e4a;
	width: 100%;
	padding: 14px 0;
	background: transparent;
	-moz-appearance: textfield;
	appearance: textfield;
}
.mollie-donation-input::-webkit-outer-spin-button,
.mollie-donation-input::-webkit-inner-spin-button { -webkit-appearance: none; }
.mollie-donation-btn {
	border: none;
	border-radius: 50px;
	padding: 14px 36px;
	font-size: 16px;
	font-weight: 700;
	letter-spacing: 1px;
	cursor: pointer;
	transition: opacity 0.15s, transform 0.1s;
	white-space: nowrap;
	box-shadow: 0 2px 6px rgba(0,0,0,0.12);
}
.mollie-donation-btn:hover { opacity: 0.88; transform: translateY(-1px); }
.mollie-donation-btn:active { transform: translateY(0); }

/* A page that already has its own bond buttons only needs the shortcode for the
   popup itself, so wrapping it in .md-bonds-host hides the duplicate button.
   The button, not the host: the popup is moved to <body> on init, but a hidden
   host would still swallow it on the no-JS fallback. */
.md-bonds-host .mollie-donation-btn { display: none; }

.md-amount-error {
	display: block;
	color: #c62828;
	font-size: 14px;
	margin-top: 6px;
}

/* ── Popup modal ── */
/* Flat selectors on purpose: native CSS nesting needs Safari 17.2+/Chrome 120+,
   and older engines drop the whole nested block — leaving the payment popup
   completely unstyled. */
.md-modal {
	position: fixed;
	inset: 0;
	z-index: 999999;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 20px;
}

/* ── Popup fields ── */
.md-modal .md-field {
	margin: 0 0 14px;
	padding-bottom: 0;
}
.md-modal .md-input {
	width: 100%;
	padding: 11px 14px;
	border: 1px solid #0E3350;
	border-radius: 60px;
	font-size: 15px;
	color: #1a2e4a;
	background: #fff;
	transition: border-color 0.15s, box-shadow 0.15s;
}

/* A pill shape only works for one-liners */
.md-modal .md-textarea {
	display: block;
	border-radius: 16px;
	padding: 12px 16px;
	font-family: inherit;
	line-height: 1.5;
	resize: vertical;
}
.md-modal .md-field label {
	display: block;
	font-size: 14px;
	font-weight: 600;
	color: #1a2e4a;
	margin-bottom: 5px;
}
.md-modal .md-req { color: #c62828; }
.md-modal .md-input:focus {
	outline: none;
	border-color: #0E3350;
	box-shadow: 0 0 0 3px rgba(14, 51, 80, 0.15);
}
/* Same specificity as :focus above and later in the file, so the error colour
   holds whether or not the field has focus. */
.md-modal .md-input.md-input-error { border-color: #c62828; }
.md-modal .md-field-error {
	display: block;
	color: #c62828;
	font-size: 13px;
	margin-top: 4px;
}

/* ── Bond calculator step ── */
.md-modal .md-step[hidden] { display: none; }

.md-modal .md-bond-notice {
	border: 1px solid #0E3350;
	padding: 10px 14px;
	margin: 0 0 22px;
	font-size: 13px;
	line-height: 1.45;
	color: #1a2e4a;
	text-align: center;
}

.md-modal .md-bond-calc {
	display: flex;
	flex-wrap: wrap;
	align-items: flex-end;
	justify-content: space-between;
	gap: 12px;
	background: #f4f5f7;
	padding: 18px 20px;
	margin: 0 0 22px;
}
.md-modal .md-bond-qty label,
.md-modal .md-bond-cell-label {
	display: block;
	font-size: 13px;
	color: #1a2e4a;
	margin-bottom: 6px;
}
.md-modal .md-bond-cell { text-align: center; }
.md-modal .md-bond-cell-value {
	display: block;
	font-size: 16px;
	font-weight: 600;
	color: #1a2e4a;
}
.md-modal .md-bond-op {
	align-self: center;
	font-size: 20px;
	font-weight: 700;
	color: #0a84ff;
	padding-top: 18px;
}

.md-modal .md-bond-stepper {
	display: flex;
	align-items: center;
	border: 1px solid #0E3350;
	border-radius: 4px;
	background: #fff;
	overflow: hidden;
}
.md-modal .md-bond-qty-input {
	width: 64px;
	border: 0;
	padding: 8px 10px;
	font-size: 15px;
	color: #1a2e4a;
	background: transparent;
	-moz-appearance: textfield;
	appearance: textfield;
}
.md-modal .md-bond-qty-input::-webkit-outer-spin-button,
.md-modal .md-bond-qty-input::-webkit-inner-spin-button {
	-webkit-appearance: none;
	margin: 0;
}
.md-modal .md-bond-qty-input:focus { outline: none; }
.md-modal .md-bond-stepper:focus-within { box-shadow: 0 0 0 2px rgba(14, 51, 80, 0.25); }
.md-modal .md-bond-step {
	border: 0;
	background: transparent;
	cursor: pointer;
	padding: 8px 10px;
	font-size: 16px;
	line-height: 1;
	color: #1a2e4a;
}
.md-modal .md-bond-step:hover { color: #0a84ff; }

.md-modal .md-bond-facts {
	width: 100%;
	border-collapse: collapse;
	margin: 0 0 22px;
	font-size: 14px;
}
.md-modal .md-bond-facts th,
.md-modal .md-bond-facts td {
	border-bottom: 1px solid #e3e6ea;
	padding: 11px 0;
	color: #1a2e4a;
	font-weight: 400;
}
.md-modal .md-bond-facts th { text-align: left; }
.md-modal .md-bond-facts td { text-align: right; }

.md-modal .md-bond-foot {
	display: flex;
	flex-wrap: wrap;
	gap: 12px;
	align-items: center;
	justify-content: space-between;
}
.md-modal .md-bond-links {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
}
.md-modal .md-bond-link {
	background: #e9ebee;
	color: #1a2e4a;
	text-decoration: none;
	font-size: 11px;
	letter-spacing: 0.06em;
	padding: 7px 12px;
	border-radius: 3px;
}
.md-modal .md-bond-link:hover { background: #dcdfe4; }
.md-modal .md-bond-next {
	border: 0;
	cursor: pointer;
	background: #bfe4f5;
	color: #0E3350;
	font-size: 13px;
	letter-spacing: 0.06em;
	padding: 12px 34px;
	border-radius: 60px;
}
.md-modal .md-bond-next:hover { background: #a9daf0; }

.md-modal .md-back {
	border: 0;
	background: transparent;
	cursor: pointer;
	padding: 0 0 12px;
	font-size: 13px;
	color: #1a2e4a;
}
.md-modal .md-back:hover { color: #0a84ff; }

@media (max-width: 480px) {
	.md-modal .md-bond-calc {
		flex-direction: column;
		align-items: stretch;
		text-align: left;
	}
	.md-modal .md-bond-cell { text-align: left; }
	.md-modal .md-bond-op { display: none; }
	.md-modal .md-bond-foot { flex-direction: column; align-items: stretch; }
	.md-modal .md-bond-next { width: 100%; }
}

/* ── "Invest with a company" toggle + section ── */
.md-modal .md-company { margin: 0 0 18px; }
.md-modal .md-toggle-row { margin: 0 0 14px; }

/* The real checkbox stays in the form (and reachable by keyboard); the label
   draws the switch. Clipped rather than display:none so it keeps focus. */
.md-modal .md-toggle-input {
	position: absolute;
	width: 1px;
	height: 1px;
	margin: -1px;
	padding: 0;
	overflow: hidden;
	clip: rect(0 0 0 0);
	white-space: nowrap;
	border: 0;
}
.md-modal .md-toggle {
	display: flex;
	gap: 12px;
	align-items: center;
	cursor: pointer;
	font-size: 14px;
	color: #1a2e4a;
}
.md-modal .md-toggle-track {
	flex: 0 0 auto;
	position: relative;
	width: 46px;
	height: 26px;
	border-radius: 26px;
	background: #d4d9e0;
	transition: background-color 0.18s;
}
.md-modal .md-toggle-thumb {
	position: absolute;
	top: 3px;
	left: 3px;
	width: 20px;
	height: 20px;
	border-radius: 50%;
	background: #fff;
	box-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
	transition: transform 0.18s;
}
.md-modal .md-toggle-input:checked + .md-toggle .md-toggle-track { background: #0a84ff; }
.md-modal .md-toggle-input:checked + .md-toggle .md-toggle-thumb { transform: translateX(20px); }
.md-modal .md-toggle-input:focus-visible + .md-toggle .md-toggle-track {
	outline: 2px solid #0E3350;
	outline-offset: 2px;
}

.md-modal .md-company-fields {
	margin-bottom: 26px;
}
.md-modal .md-company-fields .md-field:last-child { margin-bottom: 0; }

/* ── Consent checkboxes ── */
.md-modal .md-consents {
	margin-top: 22px;
	display: flex;
	flex-direction: column;
	gap: 20px;
}
.md-modal .md-consent-group-title {
	margin: 0 0 10px;
	font-size: 14px;
	font-weight: 600;
	line-height: 1.4;
	color: #1a2e4a;
}
.md-modal .md-consent-group .md-consent:last-child { margin-bottom: 0; }
.md-modal .md-consent { margin: 0 0 10px; }
.md-modal p.md-consent { padding-bottom: 8px; }
.md-modal .md-consent label {
	display: flex;
	gap: 10px;
	align-items: flex-start;
	font-size: 13.5px;
	line-height: 1.5;
	color: #3a4a5a;
	cursor: pointer;
}
.md-modal .md-consent input[type="checkbox"] {
	margin-top: 2px;
	flex-shrink: 0;
	width: 17px;
	height: 17px;
}
.md-modal .md-consent-error label { color: #c62828; }
.md-modal .md-consent a { color: #1a6e9e; }

/* ── Error summary box ── */
.md-modal .md-errors {
	border: 1.5px solid #ef5350;
	background: #fff5f5;
	border-radius: 10px;
	padding: 12px 16px;
	margin: 0 0 16px;
	font-size: 14px;
	color: #8c2020;
}
.md-modal .md-errors ul { margin: 6px 0 0; padding-left: 18px; }
.md-modal .md-errors li { margin-bottom: 2px; }

/* ── Popup submit ── */
.md-modal .md-submit {
	display: inline-block;
	width: auto;
	border: none;
	border-radius: 50px;
	padding: 14px 16px;
	font-size: 16px;
	font-weight: 700;
	letter-spacing: 0.5px;
	cursor: pointer;
	transition: opacity 0.15s, transform 0.1s;
	box-shadow: 0 2px 6px rgba(0,0,0,0.12);
}
.md-modal .md-submit:hover { opacity: 0.88; transform: translateY(-1px); }
.md-modal .md-submit:active { transform: translateY(0); }
.md-modal[hidden] { display: none; }
.md-modal-overlay {
	position: absolute;
	inset: 0;
	background: rgba(10, 25, 41, 0.55);
}
.md-modal-dialog {
	position: relative;
	margin: auto;
	background: #fff;
	border-radius: 0;
	box-shadow: 0 20px 60px rgba(0,0,0,0.3);
	width: 70%;
	max-width: 784px;
	max-height: 100%;
	overflow-y: auto;
	padding: 32px 32px 28px;
	text-align: left;
	animation: md-modal-in 0.18s ease-out;
	/* Firefox scrollbar (thin ≈ 8px; 4px is not settable there) */
	scrollbar-width: thin;
	scrollbar-color: #0E3350 rgba(14, 51, 80, 0.15);
}
/* WebKit/Blink custom scrollbar: 4px, thumb in field-border color,
   track the same color at lower opacity */
.md-modal-dialog::-webkit-scrollbar { width: 8px; }
.md-modal-dialog::-webkit-scrollbar-track { background: rgba(14, 51, 80, 0.15); }
.md-modal-dialog::-webkit-scrollbar-thumb { background: #0E3350; border-radius: 2px; }
@keyframes md-modal-in {
	from { opacity: 0; transform: translateY(12px) scale(0.98); }
	to   { opacity: 1; transform: none; }
}
.md-modal-close {
	position: absolute;
	top: 10px;
	right: 12px;
	border: none;
	background: transparent;
	font-size: 26px;
	line-height: 1;
	cursor: pointer;
	color: #7a8a99;
	padding: 6px;
}
.md-modal-close:hover { color: #1a2e4a; }
.md-modal-title {
	margin: 0 0 8px;
	font-size: 22px;
	font-weight: 700;
	color: #1a2e4a;
}
.md-modal-intro {
	margin: 0 0 14px;
	font-size: 14.5px;
	line-height: 1.55;
	color: #4a5a6a;
}
.md-modal-notice {
	margin: 0 0 16px;
	font-size: 14.5px;
	line-height: 1.6;
	color: #4a5a6a;
}
.md-modal-notice p { margin: 0 0 10px; }
.md-modal-notice p:last-child { margin-bottom: 0; }
.md-modal-notice a { color: #1a6e9e; }
.md-modal-amount {
	margin: 0 0 16px;
	padding: 10px 16px;
	background: #f0f7fb;
	border-radius: 10px;
	font-size: 16px;
	color: #1a2e4a;
}
.md-modal-fields { margin-bottom: 18px; }

body.md-modal-open { overflow: hidden; }


@media (max-width: 480px) {
	.mdf-status-card { flex-direction: column; gap: 14px; padding: 18px; }
	.mollie-donation-row { flex-direction: column; }
	.mollie-donation-btn { width: 100%; text-align: center; }
	.md-modal-dialog { width: 100%; padding: 24px 20px; }
}
