html, body.mgk-auth-screen-body { margin: 0; padding: 0; }
body.mgk-auth-screen-body { background: var(--auth-page); -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }

.mgk-auth-screen--page {
	position: relative;
	isolation: isolate;
	box-sizing: border-box;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	width: 100%;
	min-height: 100vh;
	min-height: 100dvh;
	margin: 0;
	padding: 104px 16px;
	background: var(--auth-page) var(--auth-bg-desktop) center / cover no-repeat;
	color: var(--auth-ink);
	font: var(--auth-weight-body) 14px/20px var(--auth-font);
}
.mgk-auth-screen--page::before {
	content: "";
	position: absolute;
	inset: 0;
	z-index: -1;
	background: var(--auth-overlay);
}
.mgk-auth-screen--page:focus { outline: none; }
.mgk-auth-screen--page [hidden] { display: none !important; }
.mgk-auth-screen--page *,
.mgk-auth-screen--page *::before,
.mgk-auth-screen--page *::after { box-sizing: border-box; }

.mgk-auth-screen--page .mgk-auth-screen__logo { position: absolute; top: calc(71px - var(--auth-logo-height) / 2); left: 64px; display: flex; align-items: center; gap: calc(var(--auth-logo-height) * 10 / 42); width: max-content; height: var(--auth-logo-height); color: var(--auth-logo-ink); text-decoration: none; }
.mgk-auth-screen--page .mgk-auth-screen__logo img { display: block; width: var(--auth-logo-width); height: 100%; }

.mgk-auth-screen--page .mgk-auth-screen__wordmark { display: block; font: var(--auth-weight-heading) calc(var(--auth-logo-height) * 20 / 42)/calc(var(--auth-logo-height) * 24 / 42) var(--auth-heading); white-space: nowrap; }
.mgk-auth-screen--page .mgk-auth-screen__legal {
	position: absolute;
	right: 0;
	bottom: 44px;
	left: 0;
	margin: 0;
	color: var(--auth-muted);
	font: var(--auth-weight-body) 12px/20px var(--auth-font);
	text-align: center;
}
.mgk-auth-screen--page .mgk-auth-screen__legal-sep { white-space: pre; }
.mgk-auth-screen--page .mgk-auth-screen__legal a { color: inherit; text-decoration: none; }
.mgk-auth-screen--page .mgk-auth-screen__legal a:hover { text-decoration: underline; }

.mgk-auth-screen--page[data-mgk-auth-screen-current="password-updated"] .mgk-auth-screen__legal { display: none; }

.mgk-auth-screen--page .mgk-auth-screen__card {
	width: 440px;
	max-width: 100%;
	margin: 0;

	padding: calc(var(--auth-card-padding) - 1px);
	border: 1px solid var(--auth-border);
	border-radius: var(--auth-radius-card);
	background: #fff;
	box-shadow: var(--auth-shadow);
}
.mgk-auth-screen--page .mgk-auth-screen__view { display: flex; flex-direction: column; gap: 24px; }
.mgk-auth-screen--page .mgk-auth-screen__head { display: flex; flex-direction: column; gap: 8px; }
.mgk-auth-screen--page .mgk-auth-screen__status { display: flex; flex-direction: column; gap: 16px; }
.mgk-auth-screen--page .mgk-auth-screen__title {
	margin: 0;
	color: var(--auth-ink);
	font: var(--auth-weight-heading) 24px/32px var(--auth-heading);
	letter-spacing: var(--auth-title-tracking);
}
.mgk-auth-screen--page .mgk-auth-screen__title:focus { outline: none; }
.mgk-auth-screen--page .mgk-auth-screen__lead { margin: 0; color: var(--auth-muted); font: var(--auth-weight-body) 14px/20px var(--auth-font); overflow-wrap: anywhere; }
.mgk-auth-screen--page .mgk-auth-screen__lead strong { color: inherit; font-weight: inherit; }
.mgk-auth-screen--page .mgk-auth-screen__badge {
	display: grid;
	place-items: center;
	width: 48px;
	height: 48px;
	border-radius: 24px;
	background: var(--auth-soft);
	color: var(--auth-brand);
}
.mgk-auth-screen--page .mgk-auth-screen__badge svg { display: block; }
.mgk-auth-screen--page .mgk-auth-screen__badge--success { background: none; }

.mgk-auth-screen--page .mgk-auth-screen__banner {
	margin: 0;
	padding: 12px;
	border-radius: var(--auth-radius-feedback);
	background: var(--auth-soft);
	color: var(--auth-ink);
	font: var(--auth-weight-body) 14px/20px var(--auth-font);
}
.mgk-auth-screen--page .mgk-auth-screen__status-line { margin: 0; color: var(--auth-success); font: var(--auth-weight-label) 14px/20px var(--auth-font); }

.mgk-auth-screen--page .mgk-auth-screen__form { display: flex; flex-direction: column; gap: 18px; margin: 0; }
.mgk-auth-screen--page .mgk-auth-screen__field { display: flex; flex-direction: column; margin: 0; }
.mgk-auth-screen--page .mgk-auth-screen__label {
	display: block;
	margin: 0 0 8px;
	color: var(--auth-ink);
	font: var(--auth-weight-label) 14px/20px var(--auth-font);
	letter-spacing: normal;
	text-transform: none;
}
.mgk-auth-screen--page .mgk-auth-screen__control { position: relative; }
.mgk-auth-screen--page .mgk-auth-screen__input {
	display: block;
	width: 100%;
	height: 48px;
	min-height: 48px;
	margin: 0;
	padding: 2px 14px;
	border: 1px solid var(--auth-field);
	border-radius: var(--auth-radius-field);
	background: #fff;
	box-shadow: none;
	color: var(--auth-ink);
	font: var(--auth-weight-body) 16px/24px var(--auth-font);
	outline: none;
	appearance: none;
	transition: border-color var(--auth-transition, 150ms ease), box-shadow 150ms ease;
}
.mgk-auth-screen--page .mgk-auth-screen__input::placeholder { color: var(--auth-muted); opacity: 1; }
.mgk-auth-screen--page .mgk-auth-screen__control--password .mgk-auth-screen__input { padding-right: 52px; }
.mgk-auth-screen--page .mgk-auth-screen__input[aria-invalid="true"] { border-color: var(--auth-error); }
.mgk-auth-screen--page .mgk-auth-screen__input:focus-visible {
	border-color: var(--auth-brand);
	box-shadow: 0 0 0 1px var(--auth-brand), 0 0 0 4px var(--auth-focus-ring);
}
.mgk-auth-screen--page .mgk-auth-screen__input[aria-invalid="true"]:focus-visible {
	border-color: var(--auth-error);
	box-shadow: 0 0 0 1px var(--auth-error), 0 0 0 4px var(--auth-focus-ring);
}
.mgk-auth-screen--page .mgk-auth-screen__input:read-only { cursor: default; }
.mgk-auth-screen--page .mgk-auth-screen__hint { margin: 6px 0 0; color: var(--auth-muted); font: var(--auth-weight-body) 14px/20px var(--auth-font); overflow-wrap: anywhere; }

.mgk-auth-screen--page .mgk-auth-screen__eye {
	position: absolute;
	top: 14px;
	right: 14px;
	display: grid;
	place-items: center;
	width: 20px;
	height: 20px;
	margin: 0;
	padding: 0;
	border: 0;
	border-radius: 4px;
	background: transparent;
	color: var(--auth-muted);
	cursor: pointer;
	opacity: 1;
}
.mgk-auth-screen--page .mgk-auth-screen__eye svg { display: block; width: 20px; height: 20px; }
.mgk-auth-screen--page .mgk-auth-screen__eye .mgk-auth-screen__eye-icon--open,
.mgk-auth-screen--page .mgk-auth-screen__eye[aria-pressed="true"] .mgk-auth-screen__eye-icon--closed { display: none; }
.mgk-auth-screen--page .mgk-auth-screen__eye[aria-pressed="true"] .mgk-auth-screen__eye-icon--open { display: block; }
.mgk-auth-screen--page .mgk-auth-screen__eye:focus-visible { outline: 2px solid var(--auth-brand); outline-offset: 2px; }

.mgk-auth-screen--page .mgk-auth-screen__submit {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	height: 48px;
	min-height: 48px;
	margin: 0;
	padding: 0 16px;
	border: 0;
	border-radius: var(--auth-radius-button);
	background: var(--auth-brand);
	color: var(--auth-on-brand);
	font: var(--auth-weight-button) 14px/20px var(--auth-font);
	letter-spacing: normal;
	text-transform: none;
	opacity: 1;
	cursor: pointer;
	transition: background-color 150ms ease;
}
.mgk-auth-screen--page .mgk-auth-screen__submit:hover:not(:disabled) { border: 0; background: var(--auth-brand-hover); color: var(--auth-on-brand); }
.mgk-auth-screen--page .mgk-auth-screen__submit:disabled,
.mgk-auth-screen--page .mgk-auth-screen__submit:disabled:hover {
	background: var(--auth-soft);
	color: var(--auth-muted);
	opacity: 1;
	cursor: not-allowed;
}
.mgk-auth-screen--page .mgk-auth-screen__submit:focus-visible { outline: 2px solid var(--auth-brand); outline-offset: 2px; }

.mgk-auth-screen--page .mgk-auth-screen__text-button {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	height: 40px;
	margin: 0;
	padding: 0 16px;
	border: 0;
	border-radius: var(--auth-radius-button);
	background: transparent;
	color: var(--auth-brand);
	font: var(--auth-weight-link) 14px/20px var(--auth-font);
	text-decoration: underline;
	opacity: 1;
	cursor: pointer;
}
.mgk-auth-screen--page .mgk-auth-screen__text-button--end { justify-content: flex-end; }
.mgk-auth-screen--page .mgk-auth-screen__text-button--tall { height: 48px; }
.mgk-auth-screen--page .mgk-auth-screen__actions { display: flex; flex-direction: column; gap: 8px; }

.mgk-auth-screen--page .mgk-auth-screen__switch { margin: 0; color: var(--auth-muted); font: var(--auth-weight-body) 14px/20px var(--auth-font); text-align: center; }
.mgk-auth-screen--page .mgk-auth-screen__switch a { font-weight: var(--auth-weight-link); }
.mgk-auth-screen--page .mgk-auth-screen__switch a,
.mgk-auth-screen--page .mgk-auth-screen__check-text a,
.mgk-auth-screen--page .mgk-auth-screen__link { color: var(--auth-brand); text-decoration: underline; cursor: pointer; }
.mgk-auth-screen--page .mgk-auth-screen__row { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; }
.mgk-auth-screen--page .mgk-auth-screen__link {
	margin: 0;
	padding: 0;
	border: 0;
	background: none;
	font: var(--auth-weight-link) 14px/20px var(--auth-font);
	opacity: 1;
}

.mgk-auth-screen--page .mgk-auth-screen__link[aria-disabled="true"],
.mgk-auth-screen--page .mgk-auth-screen__text-button[aria-disabled="true"] { color: var(--auth-muted); cursor: default; }
.mgk-auth-screen--page .mgk-auth-screen__text-button:hover:not([aria-disabled="true"]),
.mgk-auth-screen--page .mgk-auth-screen__link:hover:not([aria-disabled="true"]),
.mgk-auth-screen--page .mgk-auth-screen__switch a:hover,
.mgk-auth-screen--page .mgk-auth-screen__check-text a:hover { text-decoration-thickness: 2px; }
.mgk-auth-screen--page .mgk-auth-screen__text-button:focus-visible,
.mgk-auth-screen--page .mgk-auth-screen__link:focus-visible,
.mgk-auth-screen--page .mgk-auth-screen__switch a:focus-visible,
.mgk-auth-screen--page .mgk-auth-screen__check-text a:focus-visible,
.mgk-auth-screen--page .mgk-auth-screen__legal a:focus-visible,
.mgk-auth-screen--page .mgk-auth-screen__logo:focus-visible { outline: 2px solid var(--auth-brand); outline-offset: 2px; }

.mgk-auth-screen--page .mgk-auth-screen__consent { display: flex; flex-direction: column; }
.mgk-auth-screen--page .mgk-auth-screen__check { position: relative; display: flex; align-items: flex-start; gap: 8px; min-height: 44px; margin: 0; cursor: pointer; }
.mgk-auth-screen--page .mgk-auth-screen__check-input { position: absolute; top: 0; left: 0; width: 24px; height: 24px; margin: 0; opacity: 0; cursor: pointer; }
.mgk-auth-screen--page .mgk-auth-screen__check-box { flex: 0 0 24px; width: 24px; height: 24px; color: var(--auth-ink); }
.mgk-auth-screen--page .mgk-auth-screen__check-box svg { display: block; }
.mgk-auth-screen--page .mgk-auth-screen__check-on,
.mgk-auth-screen--page .mgk-auth-screen__check-input:checked + .mgk-auth-screen__check-box .mgk-auth-screen__check-off { display: none !important; }
.mgk-auth-screen--page .mgk-auth-screen__check-input:checked + .mgk-auth-screen__check-box .mgk-auth-screen__check-on { display: block !important; }
.mgk-auth-screen--page .mgk-auth-screen__check-input:focus-visible + .mgk-auth-screen__check-box { border-radius: 4px; outline: 2px solid var(--auth-brand); outline-offset: 0; }
.mgk-auth-screen--page .mgk-auth-screen__check-text { color: var(--auth-muted); font: var(--auth-weight-body) 13px/20px var(--auth-font); }
.mgk-auth-screen--page .mgk-auth-screen__consent .mgk-auth-screen__hint { margin-top: 6px; }

@media (max-width: 767px) {
	.mgk-auth-screen--page {
		--auth-card-padding: 24px;
		justify-content: flex-start;
		align-items: stretch;
		padding: 24px 16px 32px;
		background-image: var(--auth-bg-mobile);
	}
	.mgk-auth-screen--page::before { display: none; }
	.mgk-auth-screen--page .mgk-auth-screen__logo { --auth-logo-height: var(--auth-logo-height-mobile); --auth-logo-width: var(--auth-logo-width-mobile); position: static; margin: 0 0 24px; }
	.mgk-auth-screen--page .mgk-auth-screen__card { width: 100%; }
	.mgk-auth-screen--page .mgk-auth-screen__legal { display: none; }
}

@media (prefers-reduced-motion: reduce) {
	.mgk-auth-screen--page * { transition: none !important; }
}
