/* T8wn login screens (wp-login.php): one gray dialog on the text-mode desktop */
@font-face {
	font-family: "T8 VGA";
	src: url("fonts/WebPlus_IBM_VGA_9x16.woff") format("woff");
	font-display: block;
}

body.login {
	background-color: #0000AA;
	background-image: repeating-conic-gradient(#000000 0% 25%, transparent 0% 50%);
	background-size: 4px 4px;
	color: #000000;
	font-family: "T8 VGA", monospace;
	font-size: 16px;
	line-height: 20px;
	min-height: 100vh;
	display: flow-root;
}

body.login :is(p, a, label, input, button, span, div, h1) {
	font-family: "T8 VGA", monospace;
	font-size: 16px;
	line-height: 20px;
}

/* Menu bar and status bar */
.t8-login-menubar,
.t8-login-statusbar {
	position: fixed;
	left: 0;
	right: 0;
	z-index: 10;
	display: flex;
	gap: 0 2ch;
}

.t8-login-menubar {
	top: 0;
}

.t8-login-statusbar {
	bottom: 0;
}

.t8-login-statusbar a {
	padding: 0;
}

/* The dialog */
body.login #login {
	--t8-link: #0000AA;
	--t8-hover-bg: #00AA00;
	--t8-hover-fg: #000000;
	width: min(52ch, calc(100% - 48px));
	margin: 15vh auto 64px;
	padding: 0 2ch 16px;
	background: #AAAAAA;
	color: #000000;
	border: 6px double #FFFFFF;
	box-shadow: 0 0 0 8px #AAAAAA, 16px 16px 0 8px #000000;
	box-sizing: border-box;
}

body.login h1.wp-login-logo {
	width: fit-content;
	margin: -13px auto 16px;
	padding: 0 1ch;
	background: #AAAAAA;
}

body.login h1.wp-login-logo a {
	background: none;
	width: auto;
	height: auto;
	margin: 0;
	padding: 0;
	overflow: visible;
	text-indent: 0;
	color: #000000;
	text-decoration: none;
}

body.login h1.wp-login-logo a:hover,
body.login h1.wp-login-logo a:focus-visible {
	background: #00AA00;
}

body.login form {
	margin: 0;
	padding: 0;
	background: none;
	border: 0;
	box-shadow: none;
	overflow: visible;
}

body.login #login form p,
body.login #login .user-pass-wrap {
	margin: 0 0 16px;
}

body.login label {
	display: inline-block;
	margin-bottom: 4px;
	color: #000000;
}

/* Fields */
body.login form .input,
body.login input[type="text"],
body.login input[type="password"],
body.login input[type="email"] {
	width: 100%;
	height: auto;
	min-height: 0;
	margin: 0;
	padding: 2px 1ch;
	background: #000000;
	color: #FFFFFF;
	border: 0;
	border-radius: 0;
	box-shadow: none;
	font-size: 16px;
	line-height: 20px;
}

body.login .wp-pwd {
	display: flex;
	flex-wrap: wrap;
	gap: 8px 2ch;
}

body.login .wp-pwd .password-input {
	flex: 1 1 0;
	min-width: 0;
	padding-right: 1ch;
}

/* the reset page's strength meter gets its own line under the field */
body.login .wp-pwd #pass-strength-result {
	flex: 0 0 100%;
	margin: 0;
}

body.login .button.wp-hide-pw {
	position: static;
	width: auto;
	height: auto;
	min-width: 0;
	min-height: 0;
	padding: 2px 1ch;
	background: #00AA00;
	color: #000000;
	border: 0;
	border-radius: 0;
	box-shadow: none;
}

body.login .wp-hide-pw .dashicons {
	display: none;
}

body.login .wp-hide-pw::before {
	content: "Show";
}

body.login .wp-hide-pw:has(.dashicons-hidden)::before {
	content: "Hide";
}

body.login #login form p.forgetmenot {
	float: none;
	display: flex;
	align-items: center;
	gap: 1ch;
	margin-bottom: 0;
}

body.login .forgetmenot label {
	margin: 0;
}

body.login input[type="checkbox"] {
	appearance: none;
	width: auto;
	height: auto;
	min-width: 0;
	margin: 0;
	background: none;
	border: 0;
	border-radius: 0;
	box-shadow: none;
	color: #000000;
	cursor: pointer;
}

body.login input[type="checkbox"]::before,
body.login input[type="checkbox"]:checked::before {
	content: "[ ]";
	float: none;
	width: auto;
	height: auto;
	margin: 0;
	font: inherit;
}

body.login input[type="checkbox"]:checked::before {
	content: "[x]";
}

body.login input:focus {
	box-shadow: none;
}

/* Help toggletip next to "Remember Me" */
body.login .wp-tooltip__toggle,
body.login .wp-tooltip__close {
	background: none;
	border: 0;
	padding: 0;
	color: #0000AA;
	box-shadow: none;
	cursor: pointer;
}

body.login .wp-tooltip__toggle .dashicons,
body.login .wp-tooltip__close .dashicons {
	display: none;
}

body.login .wp-tooltip__toggle::before {
	content: "[?]";
}

body.login .wp-tooltip__close::before {
	content: "[x]";
}

body.login .wp-tooltip__bubble {
	max-width: 40ch;
	padding: 4px 1ch;
	background: #00AAAA;
	color: #000000;
	border: 2px solid #000000;
	border-radius: 0;
	box-shadow: 8px 8px 0 #000000;
}

/* OK button */
body.login #login form p.submit {
	margin: 0;
	padding: 16px 0 8px;
	text-align: center;
}

body.login.wp-core-ui .button-primary {
	float: none;
	height: auto;
	min-height: 0;
	padding: 0 2ch;
	background: #00AA00;
	color: #000000;
	border: 0;
	border-radius: 0;
	box-shadow: 1ch 8px 0 #000000;
	text-shadow: none;
	line-height: 20px;
}

body.login.wp-core-ui .button-primary:hover,
body.login.wp-core-ui .button-primary:focus {
	background: #00AA00;
	color: #FFFFFF;
	box-shadow: 1ch 8px 0 #000000;
}

body.login.wp-core-ui .button-primary:active {
	box-shadow: none;
}

/* Messages and errors */
body.login .message,
body.login .notice,
body.login .success,
body.login #login_error {
	margin: 0 0 16px;
	padding: 0 1ch;
	background: #00AAAA;
	color: #000000;
	border: 0;
	box-shadow: none;
}

body.login #login_error,
body.login .notice-error {
	--t8-link: #FFFF55;
	background: #AA0000;
	color: #FFFFFF;
}

body.login .message p,
body.login .notice p,
body.login #login_error p {
	margin: 0;
	padding: 0;
}

/* Links under the form */
body.login #nav,
body.login #backtoblog {
	margin: 16px 0 0;
	padding: 0;
	text-align: center;
}

body.login #nav a,
body.login #backtoblog a,
body.login .privacy-policy-page-link a {
	color: var(--t8-link, #0000AA);
}

body.login .privacy-policy-page-link {
	margin: 0 auto 48px;
}
