:root {
	--kf-navy: #0f1b2d;
	--kf-navy-deep: #081422;
	--kf-navy-mid: #14324f;
	--kf-card: #ffffff;
	--kf-text: #101828;
	--kf-muted: #667085;
	--kf-line: #e4e7ec;
	--kf-blue: #2f6fed;
	--kf-blue-hover: #1f5edc;
	--kf-blue-mark: #1d4ed8;
	--kf-danger-bg: #fdecec;
	--kf-danger: #c43030;
	--kf-focus: #2f6fed;
	--kf-input-bg: #ffffff;
}

.kf-login-body {
	margin: 0;
	min-height: 100vh;
	font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
	font-synthesis: none;
	-webkit-font-smoothing: antialiased;
	-moz-osx-font-smoothing: grayscale;
	color: var(--kf-text);
	background:
		radial-gradient(circle at 18% 12%, rgba(47, 111, 237, 0.28), transparent 36%),
		radial-gradient(circle at 86% 84%, rgba(47, 111, 237, 0.14), transparent 34%),
		linear-gradient(160deg, var(--kf-navy-deep) 0%, var(--kf-navy) 48%, var(--kf-navy-mid) 100%);
}

.kf-login-body--photo {
	background-color: var(--kf-navy);
	background-image:
		radial-gradient(circle at 18% 12%, rgba(47, 111, 237, 0.2), transparent 36%),
		linear-gradient(180deg, rgba(8, 20, 34, 0.42) 0%, rgba(8, 20, 34, 0.64) 100%),
		var(--kf-login-bg-image, none);
	background-size: auto, auto, cover;
	background-position: center;
	background-repeat: no-repeat;
	background-attachment: fixed;
}

.kf-login-wrap {
	position: relative;
	box-sizing: border-box;
	min-height: 100vh;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 32px 20px;
	overflow: hidden;
}

.kf-login-wrap::before {
	position: absolute;
	inset: 0;
	background-image:
		linear-gradient(rgba(173, 200, 255, 0.055) 1px, transparent 1px),
		linear-gradient(90deg, rgba(173, 200, 255, 0.055) 1px, transparent 1px);
	background-size: 36px 36px;
	content: "";
	pointer-events: none;
}

.kf-login-card {
	position: relative;
	z-index: 1;
	box-sizing: border-box;
	width: min(100%, 560px);
	padding: 48px 48px 44px;
	border: 0;
	border-radius: 24px;
	background: var(--kf-card);
	box-shadow: 0 28px 80px rgba(4, 12, 24, 0.38);
}

.kf-login-brand {
	display: flex;
	align-items: center;
	gap: 12px;
	margin: 0 0 28px;
	padding: 0;
	border: 0;
}

.kf-login-mark {
	display: grid;
	width: 40px;
	height: 40px;
	flex-shrink: 0;
	place-items: center;
	border-radius: 12px;
	background: var(--kf-blue-mark);
	box-shadow: none;
	color: #fff;
	font-size: 13px;
	font-weight: 800;
	letter-spacing: 0.02em;
	line-height: 1;
}

.kf-login-name {
	margin: 0;
	color: var(--kf-navy);
	font-size: 18px;
	font-weight: 800;
	line-height: 1.2;
	letter-spacing: -0.02em;
}

.kf-login-tagline {
	margin: 3px 0 0;
	font-size: 12.5px;
	font-weight: 500;
	line-height: 1.3;
	color: #98a2b3;
}

.kf-login-heading {
	margin-bottom: 28px;
}

.kf-login-kicker {
	margin: 0 0 10px;
	font-size: 11px;
	font-weight: 800;
	letter-spacing: 0.18em;
	text-transform: uppercase;
	color: var(--kf-blue);
}

.kf-login-title {
	display: block;
	margin: 0;
	color: var(--kf-text);
	font-size: 32px;
	line-height: 1.18;
	letter-spacing: -0.035em;
	font-weight: 800;
}

.kf-login-title-icon {
	display: none;
}

.kf-login-lead {
	margin: 10px 0 0;
	font-size: 14.5px;
	line-height: 1.55;
	font-weight: 400;
	color: var(--kf-muted);
}

.kf-login-form {
	display: flex;
	flex-direction: column;
	width: 100%;
}

.kf-login-field {
	display: grid;
	gap: 8px;
	width: 100%;
	margin-bottom: 18px;
}

.kf-login-alert {
	min-height: 0;
	margin: -4px 0 14px;
	padding: 0;
	border-radius: 0;
	background: transparent;
	color: var(--kf-danger);
	font-size: 13px;
	line-height: 1.45;
}

.kf-login-alert:empty {
	display: none;
}

.kf-login-label {
	display: block;
	margin: 0;
	color: var(--kf-navy);
	font-size: 13.5px;
	font-weight: 700;
	line-height: 1.2;
}

.kf-login-input {
	box-sizing: border-box;
	width: 100%;
	height: 48px;
	padding: 0 14px;
	border: 1px solid var(--kf-line);
	border-radius: 12px;
	outline: none;
	background: var(--kf-input-bg);
	color: var(--kf-text);
	font: inherit;
	font-size: 15px;
	font-weight: 400;
	line-height: 1.4;
	transition: border-color 160ms ease, box-shadow 160ms ease;
}

.kf-login-input::placeholder {
	color: #98a2b3;
	font-weight: 400;
}

.kf-login-input:focus {
	border-color: var(--kf-blue);
	background: #fff;
	box-shadow: 0 0 0 4px rgba(47, 111, 237, 0.16);
}

.kf-login-form .kf-login-input {
	margin-bottom: 0;
}

.kf-login-form .kf-login-input.is-invalid {
	margin-bottom: 6px;
	border-color: var(--kf-danger);
}

.kf-login-form .kf-login-input.is-invalid:focus {
	border-color: var(--kf-danger);
	box-shadow: 0 0 0 4px rgba(196, 48, 48, 0.12);
}

.kf-field-hint {
	margin: 0 0 12px;
	font-size: 12.5px;
	font-weight: 500;
	line-height: 1.4;
	color: var(--kf-danger);
}

.kf-field-hint[hidden] {
	display: none;
}

.kf-login-password-row {
	position: relative;
	width: 100%;
}

.kf-login-password-row.is-invalid {
	margin-bottom: 0;
}

.kf-login-password-row .kf-login-input {
	padding-right: 78px;
	margin-bottom: 0;
}

.kf-login-toggle {
	position: absolute;
	top: 50%;
	right: 14px;
	transform: translateY(-50%);
	width: auto;
	height: auto;
	min-height: 0;
	padding: 0;
	border: 0;
	border-radius: 0;
	background: transparent;
	color: var(--kf-blue);
	cursor: pointer;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	font: inherit;
	font-size: 13px;
	font-weight: 700;
	line-height: 1;
}

.kf-login-toggle:hover,
.kf-login-toggle:focus-visible {
	color: var(--kf-blue-hover);
	outline: none;
}

.kf-login-toggle-icon,
.kf-login-toggle svg {
	display: none;
}

.kf-login-remember {
	display: inline-flex;
	align-items: center;
	gap: 10px;
	margin: 2px 0 22px;
	color: var(--kf-navy);
	cursor: pointer;
	font-size: 14px;
	font-weight: 600;
	user-select: none;
}

.kf-login-remember input {
	appearance: none;
	width: 16px;
	height: 16px;
	margin: 0;
	border: 1.5px solid #cfd6e4;
	border-radius: 4px;
	background: #fff;
	cursor: pointer;
}

.kf-login-remember input:checked {
	border-color: var(--kf-blue);
	background: var(--kf-blue) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath fill='none' stroke='%23fff' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round' d='M3.5 8.2l3 3 6-6'/%3E%3C/svg%3E") center / 12px 12px no-repeat;
}

.kf-login-remember input:focus-visible {
	outline: 2px solid var(--kf-focus);
	outline-offset: 2px;
}

.kf-login-submit {
	width: 100%;
	height: 50px;
	min-height: 50px;
	border: 0;
	border-radius: 12px;
	background: var(--kf-blue);
	box-shadow: 0 10px 22px rgba(47, 111, 237, 0.34);
	color: #fff;
	font-size: 16px;
	font-weight: 700;
	letter-spacing: -0.01em;
	cursor: pointer;
	transition: background 160ms ease, box-shadow 160ms ease, transform 160ms ease;
}

.kf-login-submit:hover,
.kf-login-submit:focus {
	background: var(--kf-blue-hover);
	box-shadow: 0 12px 24px rgba(31, 94, 220, 0.38);
}

.kf-login-submit:active {
	transform: translateY(1px);
}

.kf-login-submit:focus-visible {
	outline: 2px solid var(--kf-focus);
	outline-offset: 2px;
}

.kf-login-submit:disabled {
	cursor: wait;
	opacity: 0.68;
}

@media (max-width: 480px) {
	.kf-login-body,
	.kf-login-wrap {
		min-height: 100dvh;
	}

	.kf-login-body--photo {
		background-attachment: scroll;
	}

	.kf-login-wrap {
		padding: calc(20px + env(safe-area-inset-top, 0px)) 16px calc(20px + env(safe-area-inset-bottom, 0px));
		align-items: center;
	}

	.kf-login-card {
		width: 100%;
		padding: 32px 22px 28px;
		border-radius: 20px;
	}

	.kf-login-title {
		font-size: 28px;
	}

	.kf-login-input,
	.kf-login-submit {
		height: 48px;
		min-height: 48px;
	}
}
