/* Superlift account screens (create account, log in) and the 404 page. */

.auth {
	display: grid;
	grid-template-columns: minmax(0, 688fr) minmax(0, 720fr);
	min-height: 100vh;
	min-height: 100dvh;
	padding: 16px;
}

.auth__col {
	display: flex;
	flex-direction: column;
	padding: 24px 40px 32px;
}

.auth__bar {
	display: flex;
	align-items: center;
	justify-content: space-between;
	height: 44px;
}

.auth__back {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	font-size: 15px;
	font-weight: 500;
	line-height: 20px;
	color: var(--ink-2);
}

.auth__alt {
	display: none;
	font-size: 16px;
	font-weight: 600;
	line-height: 20px;
}

@media (hover: hover) {
	.auth__back:hover {
		color: var(--ink);
	}
}

.auth__main {
	display: flex;
	flex: 1;
	align-items: center;
	justify-content: center;
	padding: 48px 0;
}

.view {
	display: flex;
	flex-direction: column;
	gap: 32px;
	width: 100%;
	max-width: 400px;
}

.view__head {
	display: flex;
	flex-direction: column;
	gap: 10px;
}

.view__title {
	font-family: var(--font-display);
	font-weight: 600;
	font-size: 44px;
	line-height: 48px;
	letter-spacing: -0.035em;
}

.view__title:focus {
	outline: none;
}

.view__lede {
	font-size: 17px;
	line-height: 26px;
	color: var(--ink-2);
}

.view__lede strong {
	font-weight: 600;
	color: var(--ink);
	overflow-wrap: anywhere;
}

.form {
	display: flex;
	flex-direction: column;
	gap: 32px;
}

.fields {
	display: flex;
	flex-direction: column;
	gap: 18px;
}

.field {
	display: flex;
	flex-direction: column;
	gap: 8px;
}

.field__labelrow {
	display: flex;
	align-items: center;
	justify-content: space-between;
}

.field label {
	font-size: 14px;
	font-weight: 500;
	line-height: 18px;
}

.input {
	display: flex;
	align-items: center;
	gap: 8px;
	height: 54px;
	padding: 0 6px 0 18px;
	border-radius: 14px;
	background: var(--surface);
	transition:
		box-shadow 140ms ease-out,
		background-color 140ms ease-out;
}

.input:focus-within {
	background: #fff;
	box-shadow:
		inset 0 0 0 2px var(--accent),
		0 0 0 4px var(--accent-soft);
}

.input input {
	flex: 1;
	min-width: 0;
	height: 100%;
	padding: 0;
	border: 0;
	outline: 0;
	background: transparent;
	font: inherit;
	font-size: 16px;
	color: var(--ink);
}

.input input::placeholder {
	color: var(--ink-3);
	opacity: 1;
}

.input--invalid,
.input--invalid:focus-within {
	background: #fff;
	box-shadow: inset 0 0 0 1.5px #e5533a;
}

.reveal {
	display: grid;
	flex-shrink: 0;
	place-items: center;
	width: 44px;
	height: 44px;
	padding: 0;
	border: 0;
	border-radius: 10px;
	background: transparent;
	color: var(--ink-3);
	cursor: pointer;
}

.reveal[aria-pressed='true'] {
	color: var(--ink);
}

.field__hint {
	font-size: 13px;
	line-height: 18px;
	color: var(--ink-2);
}

.field__hint--error {
	font-weight: 500;
	color: var(--danger);
}

.link-btn {
	padding: 0;
	border: 0;
	background: none;
	font-size: 14px;
	font-weight: 600;
	line-height: 18px;
	color: var(--accent-ink);
	cursor: pointer;
}

.notice {
	display: flex;
	align-items: flex-start;
	gap: 10px;
	padding: 14px 16px;
	border-radius: 14px;
	background: var(--surface);
	font-size: 14px;
	font-weight: 500;
	line-height: 20px;
}

.notice svg {
	flex-shrink: 0;
	margin-top: 1px;
}

.notice--error {
	background: var(--danger-soft);
	color: var(--danger-ink);
}

.actions {
	display: flex;
	flex-direction: column;
	gap: 14px;
}

.actions .btn {
	width: 100%;
	height: 54px;
}

.fine {
	font-size: 13px;
	line-height: 18px;
	color: var(--ink-2);
	text-align: center;
}

.fine a,
.fine button {
	padding: 0;
	border: 0;
	background: none;
	font: inherit;
	color: var(--ink);
	text-decoration: underline;
	text-underline-offset: 2px;
	cursor: pointer;
}

.fine button:disabled {
	color: var(--ink-2);
	text-decoration: none;
	cursor: default;
}

.switch {
	padding-top: 20px;
	border-top: 1px solid var(--line);
	font-size: 15px;
	line-height: 20px;
	color: var(--ink-2);
	text-align: center;
}

.switch a,
.switch button {
	padding: 0;
	border: 0;
	background: none;
	font: inherit;
	font-weight: 600;
	color: var(--accent-ink);
	cursor: pointer;
}

.code {
	display: flex;
	gap: 10px;
}

.code input {
	flex: 1 1 0;
	width: 0;
	min-width: 0;
	height: 64px;
	padding: 0;
	border: 0;
	border-radius: 14px;
	outline: 0;
	background: var(--surface);
	font-family: var(--font-display);
	font-weight: 600;
	font-size: 26px;
	line-height: 30px;
	text-align: center;
	color: var(--ink);
	caret-color: var(--ink);
	transition:
		box-shadow 140ms ease-out,
		background-color 140ms ease-out;
}

.code input:focus {
	background: #fff;
	box-shadow:
		inset 0 0 0 2px var(--accent),
		0 0 0 4px var(--accent-soft);
}

.code--invalid input {
	box-shadow: inset 0 0 0 1.5px #e5533a;
}

.done-mark {
	display: grid;
	place-items: center;
	width: 64px;
	height: 64px;
	border-radius: 20px;
	background: var(--accent);
	box-shadow: 0 12px 24px rgb(255 89 58 / 0.3);
	animation: pop 360ms cubic-bezier(0.2, 0.9, 0.3, 1.2) both;
}

@keyframes pop {
	from {
		transform: scale(0.6);
		opacity: 0;
	}
}

/* ---------- Brand panel (right side) ---------- */

.brand {
	position: relative;
	overflow: hidden;
	overflow: clip;
	border-radius: 28px;
	padding: 48px 52px;
	background-color: #fff6f1;
	background-image:
		radial-gradient(ellipse 70% 55% at 50% 78% in oklab, #ffc6ae 0%, #ffe6d9 50%, #fff6f100 100%),
		radial-gradient(ellipse 45% 40% at 12% 30% in oklab, #ffe7b8b3 0%, #fff6f100 100%);
}

.brand__caption {
	position: relative;
	z-index: 1;
	font-family: var(--font-display);
	font-weight: 600;
	font-size: 34px;
	line-height: 38px;
	letter-spacing: -0.03em;
}

/* The phone export is cut 668px down (where the design's panel crops it).
   Keep that line at or below the panel's bottom edge: on tall screens the
   phone slides down, on short ones it stays 200px from the top. */
.brand__cluster {
	position: absolute;
	top: max(200px, calc(100% - 668px));
	/* The phone's centre (146 + 174 = 320px in) sits on the panel's centre. */
	left: calc(50% - 320px);
	width: 650px;
	height: 716px;
	transform-origin: 320px 0;
}

.brand__cluster .phone {
	position: absolute;
	top: 0;
	left: 146px;
}

.brand__cluster .card-progress {
	position: absolute;
	top: 340px;
	left: 0;
	background: #fff;
}

.brand__cluster .card-cheer {
	position: absolute;
	top: 440px;
	left: 350px;
}

@media (max-width: 1180px) {
	.brand__cluster {
		transform: scale(0.86);
	}
}

@media (max-width: 959px) {
	.auth {
		display: block;
		padding: 0;
	}

	.brand {
		display: none;
	}

	.auth__col {
		min-height: 100vh;
		min-height: 100dvh;
		padding: 12px 20px 24px;
	}

	.auth__back {
		display: none;
	}

	.auth__alt {
		display: inline;
	}

	.auth__main {
		align-items: flex-start;
		padding: 36px 0 24px;
	}

	.view {
		gap: 28px;
	}
}

@media (max-width: 480px) {
	.view__title {
		font-size: 36px;
		line-height: 40px;
	}

	.view__head {
		gap: 8px;
	}

	.view__lede {
		font-size: 16px;
		line-height: 24px;
	}

	.fields {
		gap: 16px;
	}

	.input {
		padding-left: 16px;
	}

	.code {
		gap: 8px;
	}
}

/* ---------- 404 ---------- */

.notfound {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	gap: 20px;
	min-height: 100vh;
	min-height: 100dvh;
	padding: 24px;
	text-align: center;
}
