@font-face {
	font-family: "Nunito";
	src:
		url("/assets/fonts/Nunito-Regular.woff2") format("woff2"),
		url("/assets/fonts/Nunito-Regular.woff") format("woff");
	font-style: normal;
	font-weight: 400;
	font-display: swap;
}

@font-face {
	font-family: "Nunito";
	src:
		url("/assets/fonts/Nunito-Bold.woff2") format("woff2"),
		url("/assets/fonts/Nunito-Bold.woff") format("woff");
	font-style: normal;
	font-weight: 700;
	font-display: swap;
}

:root {
	--brand-purple: #3f145b;
	--brand-purple-dark: #2b0e3f;
	--text-heading: #1a1a1a;
	--text-body: #595959;
	--text-error: #b3261e;
	--border: #767676;
	--font: "Nunito", "Helvetica Neue", Helvetica, Arial, sans-serif;
}

* {
	box-sizing: border-box;
}

html,
body {
	min-height: 100%;
}

body {
	margin: 0;
	padding: 1.5rem 1rem;
	background-color: var(--brand-purple);
	font-family: var(--font);
	font-size: 16px;
	color: var(--text-body);
}

main {
	max-width: 400px;
	margin: 0 auto;
}

.logo {
	display: block;
	width: 315px;
	/* Scoped to viewport width, not the (narrower) .card/main column, since the logo is now
	   a sibling of main and is meant to be free to exceed the card's width. */
	max-width: 92vw;
	height: auto;
	margin: 1.5rem auto 2rem;
}

.card {
	background-color: #ffffff;
	border-radius: 16px;
	box-shadow:
		0 0 20px 0 rgba(0, 0, 0, 0.2),
		0 5px 5px 0 rgba(0, 0, 0, 0.24);
	padding: 2rem 1.75rem;
}

h1 {
	margin: 0 0 1.5rem;
	font-size: 1.375rem;
	font-weight: 700;
	color: var(--text-heading);
	text-align: center;
	line-height: 1.3;
}

label {
	display: block;
	margin-bottom: 0.4rem;
	font-size: 0.9rem;
	color: var(--text-body);
}

input[type="text"],
select {
	font: inherit;
	display: block;
	box-sizing: border-box;
	width: 100%;
	padding: 0.85rem 1rem;
	border: 1px solid var(--border);
	border-radius: 8px;
	background-color: #ffffff;
	color: var(--text-heading);
}

input[type="text"]:focus-visible,
select:focus-visible,
button:focus-visible {
	outline: 3px solid var(--brand-purple);
	outline-offset: 2px;
}

.invalid input[type="text"] {
	border-color: var(--text-error);
}

#text-group,
#select-group {
	margin-bottom: 1rem;
}

#server-help {
	margin: 0 0 1.5rem;
	font-size: 0.8rem;
	text-align: center;
}

.form-error {
	margin: 0 0 1rem;
	font-size: 0.85rem;
	color: var(--text-error);
	font-weight: 700;
}

/* Visually hidden but still announced by assistive tech (e.g. button-hint, A6). */
.visually-hidden {
	position: absolute;
	width: 1px;
	height: 1px;
	padding: 0;
	margin: -1px;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	white-space: nowrap;
	border: 0;
}

button {
	font: inherit;
	display: block;
	box-sizing: border-box;
	width: 100%;
	min-height: 44px;
	padding: 0.85rem 1rem;
	border: 0;
	border-radius: 999px;
	background-color: var(--brand-purple);
	color: #ffffff;
	font-weight: 700;
	cursor: pointer;
}

button:hover:enabled {
	background-color: var(--brand-purple-dark);
}

button:disabled {
	opacity: 0.5;
	cursor: not-allowed;
}

.continue-anyway {
	background-color: transparent;
	color: var(--brand-purple);
	text-decoration: underline;
	font-weight: 400;
	margin-top: 0.5rem;
}

@media (min-width: 480px) {
	body {
		padding: 3rem 1rem;
	}
}
