.km-membership-login-page {
	margin: 0;
	min-height: 100vh;
	background: linear-gradient(135deg, #004785 0%, #0a7bc2 60%, #27b8d6 100%);
	font-family: "Helvetica Neue", Arial, "Hiragino Kaku Gothic ProN", "Meiryo", sans-serif;
	color: #0b2a44;
	display: flex;
	/* Changed from align-items: center to allow safer scrolling */
	flex-direction: column;
	overflow-y: auto;
	/* Prevent horizontal scrolling when inner elements shrink poorly on small screens */
	overflow-x: hidden;
}

.km-membership-login-page .km-login-wrapper {
	width: 100%;
	/* Reduced padding */
	padding: 24px 16px;
	display: flex;
	justify-content: center;
	/* Keep content nearer the top while leaving breathing room */
	margin: 32px 0 40px;
	box-sizing: border-box;
}

.km-membership-login-page .km-login-panel {
	max-width: 420px;
	width: min(100%, 420px);
	background: #ffffff;
	border-radius: 16px;
	box-shadow: 0 24px 48px rgba(0, 34, 85, 0.18);
	/* Compact padding */
	padding: 32px 28px 36px;
	box-sizing: border-box;
}

.km-membership-login-page .km-login-brand {
	display: flex;
	align-items: center;
	gap: 12px;
	/* Reduced margin */
	margin-bottom: 20px;
}

.km-membership-login-page .km-login-brand img {
	height: 40px; /* Slightly smaller logo */
}

.km-membership-login-page .km-login-brand span {
	font-size: 16px; /* Slightly smaller font */
	font-weight: 600;
	color: #0b2a44;
	letter-spacing: 0.04em;
}

.km-membership-login-page .km-login-title {
	font-size: 24px;
	font-weight: 700;
	/* Reduced margin */
	margin: 0 0 16px;
	color: #0b2a44;
	text-align: left;
}

.km-membership-login-page .km-login-description {
	/* Reduced margin */
	margin: 0 0 20px;
	font-size: 13px;
	line-height: 1.6;
	color: #4c6277;
}

.km-membership-login-page .km-login-messages,
.km-membership-login-page .km-login-errors {
	margin-bottom: 16px;
	padding: 10px 14px;
	border-radius: 8px;
	font-size: 13px;
	line-height: 1.5;
}

.km-membership-login-page .km-login-messages {
	background: rgba(9, 140, 78, 0.1);
	color: #056742;
	border: 1px solid rgba(9, 140, 78, 0.2);
}

.km-membership-login-page .km-login-errors {
	background: rgba(201, 42, 42, 0.1);
	color: #7d1e1e;
	border: 1px solid rgba(201, 42, 42, 0.2);
}

.km-membership-login-page label {
	display: block;
	font-size: 13px;
	font-weight: 600;
	margin-bottom: 4px; /* Reduced margin */
	color: #0b2a44;
}

.km-membership-login-page input[type="text"],
.km-membership-login-page input[type="password"],
.km-membership-login-page input[type="email"] {
	width: 100%;
	/* Compact padding */
	padding: 10px 12px;
	/* Reduced margin */
	margin-bottom: 14px;
	font-size: 15px;
	border-radius: 8px;
	border: 1px solid #c5d6e6;
	background: #f7fbff;
	box-sizing: border-box;
	transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.km-membership-login-page input[type="text"]:focus,
.km-membership-login-page input[type="password"]:focus,
.km-membership-login-page input[type="email"]:focus {
	outline: none;
	border-color: #0a7bc2;
	box-shadow: 0 0 0 3px rgba(10, 123, 194, 0.15);
}

/* Readonly fields - grayed out appearance */
.km-membership-login-page input[readonly] {
	background: #e9ecef;
	color: #6c757d;
	cursor: not-allowed;
	border-color: #ced4da;
}

.km-membership-login-page input[readonly]:focus {
	border-color: #ced4da;
	box-shadow: none;
}

/* Password requirement notice */
.km-membership-login-page .km-password-requirement {
	margin: 6px 0 0 0;
	padding: 8px 12px;
	font-size: 13px;
	color: #c92a2a;
	background: #fff5f5;
	border: 1px solid #ffc9c9;
	border-radius: 6px;
	line-height: 1.5;
}

.km-membership-login-page .km-password-requirement strong {
	font-weight: 700;
}

.km-membership-login-page .km-login-submit {
	width: 100%;
	padding: 12px 20px; /* Reduced vertical padding */
	font-size: 16px;
	font-weight: 700;
	border-radius: 999px;
	border: none;
	background: linear-gradient(135deg, #0a7bc2 0%, #27b8d6 100%);
	color: #ffffff;
	cursor: pointer;
	box-shadow: 0 12px 24px rgba(12, 104, 168, 0.25);
	transition: transform 0.15s ease, box-shadow 0.15s ease, filter 0.15s ease;
}

.km-membership-login-page .km-login-submit:hover {
	transform: translateY(-1px);
	box-shadow: 0 16px 28px rgba(12, 104, 168, 0.3);
	filter: brightness(1.03);
}

.km-membership-login-page .km-login-support {
	margin-top: 20px;
	font-size: 12px;
	color: #4c6277;
	text-align: center;
	line-height: 1.6;
}

.km-membership-login-page .km-login-support a {
	color: #0a7bc2;
	text-decoration: none;
	font-weight: 600;
}

.km-membership-login-page .km-login-support a:hover {
	text-decoration: underline;
}

.km-membership-login-page .km-login-back {
	margin-top: 16px;
	text-align: center;
	font-size: 12px;
}

.km-membership-login-page .km-login-back a {
	color: #0a7bc2;
	text-decoration: none;
	font-weight: 600;
}

.km-membership-login-page .km-login-back a:hover {
	text-decoration: underline;
}

.km-membership-login-page .km-account-section {
	margin-top: 20px;
	padding: 14px;
	background: #f4f8fc;
	border-radius: 12px;
	border: 1px solid #d5e3f3;
}

.km-membership-login-page .km-account-section h2 {
	margin: 0 0 12px;
	font-size: 15px;
	font-weight: 700;
	color: #0b2a44;
}

.km-membership-login-page .km-account-note {
	margin: 6px 0 0;
	font-size: 11px;
	color: #4c6277;
}

.km-membership-login-page .km-account-links {
	margin-top: 20px;
	text-align: center;
}

.km-membership-login-page .km-account-links a {
	color: #0a7bc2;
	font-weight: 600;
	text-decoration: none;
	font-size: 13px;
}

.km-membership-login-page .km-account-links a:hover {
	text-decoration: underline;
}

.km-membership-login-page .km-account-links__primary {
	margin-right: 16px;
}

.km-membership-login-page .km-remember {
	display: flex;
	align-items: center;
	justify-content: space-between;
	margin-bottom: 8px; /* Reduced */
	font-size: 13px;
}

.km-membership-login-page .km-remember input[type="checkbox"] {
	margin-right: 6px;
}

@media (max-width: 599px) {
	.km-membership-login-page .km-login-wrapper {
		/* Keep breathing room without forcing horizontal scroll */
		padding: 18px 12px 22px;
		margin: 20px 0 28px;
	}

	.km-membership-login-page .km-login-panel {
		/* Reduced mobile padding */
		padding: 22px 18px 26px;
	}

	.km-membership-login-page .km-login-title {
		font-size: 20px;
	}

	.km-membership-login-page .km-remember {
		flex-direction: column;
		align-items: flex-start;
		gap: 8px;
	}

	.km-membership-login-page .km-remember a {
		width: 100%;
	}
}
.km-login-info {
	margin: 10px 0 20px;
	padding: 14px 16px;
	background: #f4f8fc;
	border-radius: 8px;
	border: 1px solid #d5e3f3;
	font-size: 13px;
	color: #0b2a44;
	line-height: 1.6;
}

.km-login-info strong {
	font-weight: 700;
}

.km-login-cta__buttons {
	margin: 14px 0;
	text-align: center;
}

.km-login-cta__button {
	display: inline-block;
	padding: 8px 16px;
	border-radius: 999px;
	background: #0a7bc2;
	color: #ffffff;
	text-decoration: none;
	font-weight: 600;
	font-size: 14px;
}

.km-login-cta__button:hover {
	opacity: 0.9;
}

.km-login-error-actions {
	display: flex;
	gap: 12px;
	margin-top: 16px;
	flex-wrap: wrap;
}

.km-login-error-actions a {
	flex: 1 1 180px;
	text-align: center;
	padding: 10px 14px;
	border-radius: 999px;
	background: #0a7bc2;
	color: #ffffff;
	text-decoration: none;
	font-weight: 700;
	font-size: 14px;
	box-shadow: 0 10px 18px rgba(12, 104, 168, 0.25);
	transition: transform 0.15s ease, box-shadow 0.15s ease, filter 0.15s ease;
}

.km-login-error-actions a:hover {
	transform: translateY(-1px);
	box-shadow: 0 14px 22px rgba(12, 104, 168, 0.3);
	filter: brightness(1.03);
}

/* nomail user section */
.km-membership-login-page .km-account-section--nomail {
	background: #fff8e6;
	border-color: #f0d28a;
}

.km-membership-login-page .km-account-notice {
	margin: 0;
	font-size: 13px;
	line-height: 1.7;
	color: #5a4a1e;
}

.km-membership-login-page .km-account-notice strong {
	color: #8b6914;
}

/* Required field marker */
.km-membership-login-page .km-required {
	color: #c92a2a;
	font-weight: 600;
	font-size: 12px;
}
