/* One close control for the shared application, award-picker and vote dialogs.
   Use a real button and SVG so legacy anchor/pseudo-element rules cannot split
   the visible cross from the actual hit area. */
#openModal ~ .content2 > button.kt-modal-close {
	-webkit-appearance: none !important;
	appearance: none !important;
	position: absolute !important;
	top: 12px !important;
	right: 12px !important;
	width: 31px !important;
	min-width: 31px !important;
	height: 31px !important;
	min-height: 31px !important;
	box-sizing: border-box !important;
	display: flex !important;
	align-items: center !important;
	justify-content: center !important;
	padding: 0 !important;
	border: 1px solid #eadfed !important;
	border-radius: 50% !important;
	background: #fff !important;
	background-image: none !important;
	box-shadow: 0 4px 14px rgba(44, 25, 52, .1) !important;
	color: #4d1765 !important;
	font-size: 0 !important;
	line-height: 1 !important;
	text-align: center !important;
	cursor: pointer !important;
	touch-action: manipulation !important;
	pointer-events: auto !important;
	z-index: 100001 !important;
}

#openModal ~ .content2 > button.kt-modal-close::before,
#openModal ~ .content2 > button.kt-modal-close::after {
	display: none !important;
}

#openModal ~ .content2 > button.kt-modal-close > svg {
	display: block !important;
	width: 20px !important;
	height: 20px !important;
	fill: none !important;
	stroke: currentColor !important;
	stroke-width: 2.5 !important;
	stroke-linecap: round !important;
	pointer-events: none !important;
}

#openModal ~ .content2 > button.kt-modal-close:hover {
	border-color: #d8c3e1 !important;
	background: #f7f0fa !important;
}

#openModal ~ .content2 > button.kt-modal-close:focus-visible {
	outline: 3px solid rgba(77, 23, 101, .28) !important;
	outline-offset: 2px !important;
}

#openModal ~ .content2.kt-async-loading {
	box-sizing: border-box !important;
	position: fixed !important;
	top: 50% !important;
	left: 50% !important;
	width: min(560px, calc(100vw - 32px)) !important;
	max-height: calc(100vh - 32px) !important;
	min-height: 210px !important;
	margin: 0 !important;
	padding: 30px !important;
	transform: translate(-50%, -50%) !important;
	border: 1px solid #eadfed !important;
	border-top: 5px solid #f6c66a !important;
	border-radius: 22px !important;
	background: #fff !important;
	box-shadow: 0 24px 80px rgba(25, 10, 34, .3) !important;
	font-family: 'PT Sans Narrow', sans-serif !important;
}

#openModal ~ .content2.kt-async-loading > p {
	width: 100% !important;
	min-height: 142px !important;
	display: flex !important;
	align-items: center !important;
	justify-content: center !important;
	margin: 0 !important;
	padding: 24px 44px !important;
	color: #4d1765 !important;
	font: 700 18px/1.4 'PT Sans Narrow', sans-serif !important;
	text-align: center !important;
}

#openModal ~ .content2 .kt-modal-loading {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 12px;
}

#openModal ~ .content2 .kt-modal-spinner {
	width: 24px;
	height: 24px;
	flex: 0 0 24px;
	border: 3px solid #eadfed;
	border-top-color: #4d1765;
	border-radius: 50%;
	animation: kt-modal-spin .75s linear infinite;
}

@keyframes kt-modal-spin { to { transform: rotate(360deg); } }

@media (prefers-reduced-motion: reduce) {
	#openModal ~ .content2 .kt-modal-spinner { animation: none; }
}

/* Branded progress state while an application is being prepared for payment. */
#openModal:has(+ .content2.kt-async-loading),
#openModal:has(+ .content2:has(.kt-order-processing)) {
	background: rgba(39, 17, 49, .72) !important;
	backdrop-filter: blur(3px);
	pointer-events: auto !important;
}

#openModal ~ .content2:has(.kt-order-processing) {
	box-sizing: border-box !important;
	position: fixed !important;
	top: 50% !important;
	left: 50% !important;
	width: min(560px, calc(100vw - 32px)) !important;
	max-height: calc(100vh - 32px) !important;
	min-height: 210px !important;
	margin: 0 !important;
	padding: 30px !important;
	transform: translate(-50%, -50%) !important;
	border: 1px solid #eadfed !important;
	border-top: 5px solid #f6c66a !important;
	border-radius: 22px !important;
	background: #fff !important;
	box-shadow: 0 24px 80px rgba(25, 10, 34, .3) !important;
	font-family: 'PT Sans Narrow', sans-serif !important;
}

#openModal ~ .content2:has(.kt-order-processing) > p {
	width: 100% !important;
	margin: 0 !important;
	padding: 0 !important;
	text-align: center !important;
}

#openModal ~ .content2 .kt-order-processing {
	min-height: 142px;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	gap: 10px;
	padding: 12px 20px;
	color: #665d70;
	font: 400 16px/1.4 'PT Sans Narrow', sans-serif;
}

#openModal ~ .content2 .kt-order-processing h3 {
	margin: 0 !important;
	color: #30263a !important;
	font: 700 28px/1.2 'PT Sans Narrow', sans-serif !important;
	text-align: center !important;
}

#openModal ~ .content2 .kt-order-processing--accepted h3 {
	font-size: 22px !important;
}

#openModal ~ .content2 .kt-order-processing__spinner {
	width: 38px;
	height: 38px;
	box-sizing: border-box;
	border: 4px solid #eadfed;
	border-top-color: #4d1765;
	border-right-color: #f6c66a;
	border-radius: 50%;
	animation: kt-modal-spin .8s linear infinite;
}

#openModal ~ .content2 .kt-order-processing__message {
	color: #766280;
	font-size: 15px;
}

@media (max-width: 520px) {
	#openModal ~ .content2.kt-async-loading,
	#openModal ~ .content2:has(.kt-order-processing) {
		width: calc(100vw - 24px) !important;
		min-height: 190px !important;
		padding: 24px 16px !important;
	}
	#openModal ~ .content2.kt-async-loading > p { padding: 24px 34px !important; }
	#openModal ~ .content2 .kt-order-processing { min-height: 132px; padding: 10px 4px; }
	#openModal ~ .content2 .kt-order-processing h3 { font-size: 24px !important; }
}

@media (prefers-reduced-motion: reduce) {
	#openModal ~ .content2 .kt-order-processing__spinner { animation: none; }
}

/* Child application confirmation: the applicant closes it manually; payment is due after results. */
#openModal:has(+ .content2:has(.kt-child-application-success)) {
	background: rgba(39, 17, 49, .72) !important;
	backdrop-filter: blur(3px);
	pointer-events: auto !important;
}

#openModal ~ .content2:has(.kt-child-application-success) {
	box-sizing: border-box !important;
	position: fixed !important;
	top: 50% !important;
	left: 50% !important;
	width: min(620px, calc(100vw - 32px)) !important;
	max-height: calc(100vh - 32px) !important;
	margin: 0 !important;
	padding: 24px !important;
	transform: translate(-50%, -50%) !important;
	border: 1px solid #eadfed !important;
	border-top: 5px solid #f6c66a !important;
	border-radius: 22px !important;
	background: #fff !important;
	box-shadow: 0 24px 80px rgba(25, 10, 34, .3) !important;
	font-family: 'PT Sans Narrow', sans-serif !important;
}

#openModal ~ .content2:has(.kt-child-application-success) > p {
	width: 100% !important;
	margin: 0 !important;
	padding: 0 !important;
	text-align: left !important;
}

#openModal ~ .content2 .kt-child-application-success {
	box-sizing: border-box;
	padding: 8px 8px 2px;
	color: #30263a;
	text-align: center;
}

#openModal ~ .content2 .kt-child-success__icon {
	width: 58px;
	height: 58px;
	display: grid;
	place-items: center;
	margin: 0 auto 12px;
	border-radius: 50%;
	background: #f5edf8;
	color: #4d1765;
}

#openModal ~ .content2 .kt-child-success__icon svg {
	width: 30px;
	height: 30px;
	fill: none;
	stroke: currentColor;
	stroke-width: 2.5;
	stroke-linecap: round;
	stroke-linejoin: round;
}

#openModal ~ .content2 .kt-child-success__eyebrow {
	margin: 0 0 3px !important;
	color: #766280;
	font: 700 13px/1.3 'PT Sans Narrow', sans-serif;
	letter-spacing: .08em;
}

#openModal ~ .content2 .kt-child-application-success h3 {
	margin: 0 0 4px !important;
	color: #4d1765 !important;
	font: 700 30px/1.15 'PT Sans Narrow', sans-serif !important;
}

#openModal ~ .content2 .kt-child-success__intro {
	margin: 0 0 18px !important;
	color: #665d70;
	font: 400 17px/1.4 'PT Sans Narrow', sans-serif;
}

#openModal ~ .content2 .kt-child-success__details {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 10px;
	margin: 0 0 14px;
}

#openModal ~ .content2 .kt-child-success__details > div {
	padding: 12px 14px;
	border: 1px solid #eadfed;
	border-radius: 14px;
	background: #faf7fb;
}

#openModal ~ .content2 .kt-child-success__details span {
	display: block;
	color: #746a7e;
	font: 400 14px/1.2 'PT Sans Narrow', sans-serif;
}

#openModal ~ .content2 .kt-child-success__details strong {
	display: block;
	margin-top: 3px;
	color: #4d1765;
	font: 700 21px/1.2 'PT Sans Narrow', sans-serif;
}

#openModal ~ .content2 .kt-child-success__next {
	padding: 13px 16px;
	border-left: 4px solid #f6c66a;
	border-radius: 0 12px 12px 0;
	background: #fbf8fc;
	text-align: left;
}

#openModal ~ .content2 .kt-child-success__next strong {
	color: #4d1765;
	font: 700 18px/1.25 'PT Sans Narrow', sans-serif;
}

#openModal ~ .content2 .kt-child-success__next p {
	margin: 3px 0 0 !important;
	color: #665d70;
	font: 400 16px/1.35 'PT Sans Narrow', sans-serif;
}

@media (max-width: 520px) {
	#openModal ~ .content2:has(.kt-child-application-success) { padding: 20px 16px !important; }
	#openModal ~ .content2 .kt-child-success__details { grid-template-columns: 1fr; gap: 7px; }
	#openModal ~ .content2 .kt-child-application-success h3 { font-size: 26px !important; }
}

/* Successful cabinet-balance payment: compact branded confirmation dialog. */
#openModal:has(+ .content2:has(.kt-balance-payment-success)) {
	background: rgba(39, 17, 49, .72) !important;
	backdrop-filter: blur(3px);
	pointer-events: auto !important;
}

#openModal ~ .content2:has(.kt-balance-payment-success) {
	box-sizing: border-box !important;
	position: fixed !important;
	top: 50% !important;
	left: 50% !important;
	width: min(520px, calc(100vw - 32px)) !important;
	max-height: calc(100vh - 32px) !important;
	margin: 0 !important;
	padding: 28px !important;
	transform: translate(-50%, -50%) !important;
	border: 1px solid #eadfed !important;
	border-top: 5px solid #f6c66a !important;
	border-radius: 22px !important;
	background: #fff !important;
	box-shadow: 0 24px 80px rgba(25, 10, 34, .3) !important;
	font-family: 'PT Sans Narrow', sans-serif !important;
}

#openModal ~ .content2:has(.kt-balance-payment-success) > p {
	width: 100% !important;
	margin: 0 !important;
	padding: 0 !important;
	text-align: center !important;
}

#openModal ~ .content2 .kt-balance-payment-success {
	padding: 4px 8px;
	color: #30263a;
	text-align: center;
}

#openModal ~ .content2 .kt-balance-success__icon {
	width: 58px;
	height: 58px;
	display: grid;
	place-items: center;
	margin: 0 auto 12px;
	border-radius: 50%;
	background: #f5edf8;
	color: #4d1765;
}

#openModal ~ .content2 .kt-balance-success__icon svg {
	width: 30px;
	height: 30px;
	fill: none;
	stroke: currentColor;
	stroke-width: 2.5;
	stroke-linecap: round;
	stroke-linejoin: round;
}

#openModal ~ .content2 .kt-balance-success__eyebrow {
	margin: 0 0 4px !important;
	color: #766280;
	font: 700 13px/1.3 'PT Sans Narrow', sans-serif !important;
	letter-spacing: .08em;
}

#openModal ~ .content2 .kt-balance-payment-success h3 {
	margin: 0 0 6px !important;
	color: #4d1765 !important;
	font: 700 28px/1.2 'PT Sans Narrow', sans-serif !important;
}

#openModal ~ .content2 .kt-balance-success__description {
	margin: 0 !important;
	color: #665d70 !important;
	font: 400 17px/1.45 'PT Sans Narrow', sans-serif !important;
}

@media (max-width: 520px) {
	#openModal ~ .content2:has(.kt-balance-payment-success) { padding: 22px 16px !important; }
	#openModal ~ .content2 .kt-balance-payment-success h3 { font-size: 24px !important; }
}

/* Payment choice shown after an application when the account balance covers the invoice. */
#openModal:has(+ .content2:has(.kt-payment-choice)) {
	background: rgba(39, 17, 49, .72) !important;
	backdrop-filter: blur(3px);
	pointer-events: auto !important;
}

#openModal ~ .content2:has(.kt-payment-choice) {
	box-sizing: border-box !important;
	position: fixed !important;
	top: 50% !important;
	left: 50% !important;
	width: min(590px, calc(100vw - 32px)) !important;
	max-height: calc(100vh - 32px) !important;
	margin: 0 !important;
	padding: 30px !important;
	transform: translate(-50%, -50%) !important;
	border: 1px solid #eadfed !important;
	border-top: 5px solid #f6c66a !important;
	border-radius: 22px !important;
	background: #fff !important;
	box-shadow: 0 24px 80px rgba(25, 10, 34, .3) !important;
	font-family: 'PT Sans Narrow', sans-serif !important;
}

#openModal ~ .content2:has(.kt-payment-choice) > p {
	width: 100% !important;
	margin: 0 !important;
	padding: 0 !important;
	text-align: left !important;
}

#openModal ~ .content2 .kt-payment-choice {
	padding: 4px 8px 2px;
	color: #30263a;
}

#openModal ~ .content2 .kt-payment-choice__eyebrow {
	margin: 0 0 4px !important;
	color: #766280 !important;
	font: 700 13px/1.3 'PT Sans Narrow', sans-serif !important;
	letter-spacing: .08em;
}

#openModal ~ .content2 .kt-payment-choice h3 {
	margin: 0 0 8px !important;
	color: #4d1765 !important;
	font: 700 28px/1.2 'PT Sans Narrow', sans-serif !important;
}

#openModal ~ .content2 .kt-payment-choice__amount {
	margin: 0 0 16px !important;
	color: #665d70 !important;
	font: 400 17px/1.4 'PT Sans Narrow', sans-serif !important;
}

#openModal ~ .content2 .kt-payment-choice__amount strong { color: #4d1765; font-weight: 700; }

#openModal ~ .content2 .kt-payment-choice__balance {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	margin: 0 0 20px;
	padding: 13px 16px;
	border: 1px solid #eadfed;
	border-radius: 13px;
	background: #faf7fb;
	color: #665d70;
	font: 400 16px/1.3 'PT Sans Narrow', sans-serif;
}

#openModal ~ .content2 .kt-payment-choice__balance strong { color: #4d1765; font-size: 20px; }

#openModal ~ .content2 .kt-payment-choice__actions {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 12px;
}

#openModal ~ .content2 .kt-payment-choice__actions form { display: flex; min-width: 0; }

#openModal ~ .content2 .kt-payment-choice__button {
	appearance: none;
	box-sizing: border-box;
	display: inline-flex;
	width: 100%;
	min-height: 50px;
	align-items: center;
	justify-content: center;
	padding: 10px 16px;
	border: 1px solid #4d1765;
	border-radius: 13px;
	font: 700 17px/1.2 'PT Sans Narrow', sans-serif !important;
	text-align: center;
	text-decoration: none !important;
	cursor: pointer;
	transition: background-color .18s ease, border-color .18s ease, transform .18s ease;
}

#openModal ~ .content2 .kt-payment-choice__button--online {
	background: #4d1765 !important;
	color: #fff !important;
}

#openModal ~ .content2 .kt-payment-choice__button--balance {
	border-color: #e7d8ee;
	background: #f7f0fa !important;
	color: #4d1765 !important;
}

#openModal ~ .content2 .kt-payment-choice__button:hover,
#openModal ~ .content2 .kt-payment-choice__button:focus-visible {
	border-color: #38104c;
	background: #38104c !important;
	color: #fff !important;
	transform: translateY(-1px);
}

#openModal ~ .content2 .kt-payment-choice__button--balance:hover,
#openModal ~ .content2 .kt-payment-choice__button--balance:focus-visible {
	border-color: #4d1765;
	background: #4d1765 !important;
}

@media (max-width: 520px) {
	#openModal ~ .content2:has(.kt-payment-choice) { padding: 22px 16px !important; }
	#openModal ~ .content2 .kt-payment-choice { padding-right: 0; padding-left: 0; }
	#openModal ~ .content2 .kt-payment-choice h3 { font-size: 24px !important; }
	#openModal ~ .content2 .kt-payment-choice__actions { grid-template-columns: 1fr; }
}

/* Payment actions in search results and registries: warm text link, no button frame. */
#concurs_results .search_table a.paycount,
a.kt-registry-pay-link {
	display: inline !important;
	padding: 0 !important;
	border: 0 !important;
	border-radius: 0 !important;
	background: transparent !important;
	box-shadow: none !important;
	color: #ad6735 !important;
	font-weight: 600 !important;
	text-decoration: none !important;
}

#concurs_results .search_table a.paycount:hover,
#concurs_results .search_table a.paycount:focus-visible,
a.kt-registry-pay-link:hover,
a.kt-registry-pay-link:focus-visible {
	color: #87491f !important;
	text-decoration: underline !important;
}
