/* Mis Links PR — forms on public pages. The buttons reuse the page's link style (.mislinks-link),
   so they follow the member's design; the form itself is a clean, high-contrast card. */
.mlf { display: flex; flex-direction: column; gap: var(--mislinks-space-3, 12px); margin-top: var(--mislinks-space-3, 12px); }
:where(button.mislinks-link) { border: 0; }
button.mislinks-link { width: 100%; font: inherit; font-weight: 700; cursor: pointer; appearance: none; }

.mlf-dialog {
	width: min(520px, calc(100vw - 24px));
	max-height: calc(100dvh - 24px);
	padding: 0;
	border: 0;
	border-radius: 18px;
	background: #fff;
	color: #14103f;
	font-family: var(--mislinks-font-sans, system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif);
	box-shadow: 0 20px 60px rgba(20, 16, 63, .35);
	overflow: auto;
	overscroll-behavior: contain;
}
.mlf-dialog::backdrop { background: rgba(10, 8, 30, .6); }
.mlf-dialog[open] { animation: mlf-in .16s ease-out; }
@keyframes mlf-in { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { .mlf-dialog[open] { animation: none; } }
.mlf-card { padding: 20px; }
.mlf-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin-bottom: 8px; }
.mlf-head h2 { margin: 0; font-size: 22px; line-height: 1.2; }
.mlf-close {
	flex: none;
	width: 40px;
	height: 40px;
	margin: -6px -6px 0 0;
	border: 0;
	border-radius: 50%;
	background: #f1f0f8;
	color: #14103f;
	font-size: 26px;
	line-height: 1;
	cursor: pointer;
}
.mlf-close:focus-visible, .mlf-submit:focus-visible { outline: 3px solid #3a1fc1; outline-offset: 2px; }
.mlf-intro { margin: 0 0 14px; color: #4b4867; line-height: 1.45; }
.mlf-field { margin: 0 0 14px; }
.mlf-field > label { display: block; margin-bottom: 6px; font-weight: 700; font-size: 15px; }
.mlf-req { color: #b3261e; }
.mlf-field input:not([type="checkbox"]), .mlf-field textarea, .mlf-field select {
	display: block;
	width: 100%;
	min-height: 48px;
	padding: 10px 12px;
	border: 1.5px solid #cfcce2;
	border-radius: 12px;
	background: #fff;
	color: #14103f;
	font: inherit;
	font-size: 16px; /* No zoom on iPhone. */
	box-sizing: border-box;
}
.mlf-field textarea { min-height: 110px; resize: vertical; }
.mlf-field input:focus, .mlf-field textarea:focus, .mlf-field select:focus { outline: 3px solid rgba(58, 31, 193, .25); border-color: #3a1fc1; }
.mlf-field [aria-invalid="true"] { border-color: #b3261e; }
.mlf-check { display: flex; align-items: flex-start; gap: 10px; font-size: 15px; line-height: 1.4; cursor: pointer; }
.mlf-check input { flex: none; width: 22px; height: 22px; margin: 1px 0 0; accent-color: #3a1fc1; }
.mlf-err { margin: 6px 0 0; color: #b3261e; font-size: 14px; font-weight: 700; }
.mlf-err[hidden], .mlf-alert[hidden] { display: none; }
.mlf-alert { margin: 0 0 12px; padding: 10px 12px; border-radius: 10px; background: #fdecea; color: #8c1d18; font-weight: 700; }
.mlf-hp { position: absolute !important; left: -9999px !important; width: 1px; height: 1px; overflow: hidden; }
.mlf-turnstile { margin: 0 0 12px; }
.mlf-submit {
	display: block;
	width: 100%;
	min-height: 52px;
	padding: 12px 18px;
	border: 0;
	border-radius: 999px;
	background: var(--mislinks-color-accent, #3a1fc1);
	color: var(--ml-accent-text, #fff);
	font: inherit;
	font-size: 17px;
	font-weight: 800;
	cursor: pointer;
}
.mlf-submit:disabled { opacity: .6; cursor: progress; }
.mlf-privacy { margin: 12px 0 0; color: #6b6880; font-size: 12.5px; line-height: 1.45; }
.mlf-privacy a { color: inherit; }
.mlf-done { padding: 18px 0 4px; text-align: center; }
.mlf-done[hidden], .mlf-form[hidden] { display: none; }
.mlf-done__icon {
	display: grid;
	place-items: center;
	width: 60px;
	height: 60px;
	margin: 0 auto 12px;
	border-radius: 50%;
	background: #e6f6ec;
	color: #0a7a3d;
	font-size: 30px;
	font-weight: 800;
}
.mlf-done__msg { margin: 0 0 18px; font-size: 17px; line-height: 1.45; }
