

/* mojo/auth's login page also loads the generic (non-vista) login.css,
   which sets this via a plain `* { box-sizing: border-box }` - but this
   stylesheet is also loaded standalone by mojo/sso's Vista SSO pages
   (welcome/newuser/linkuser/errors), so every box here needs its own
   scoped reset rather than assuming that ambient one. Without it, any
   rule combining width/min-height with padding (.vista-content,
   .vista-btn, etc.) renders larger than intended and can overflow its
   parent - see WIP-9351 follow-up commits for two real instances. */
.vista-page,
.vista-page *,
.vista-page *::before,
.vista-page *::after {
	box-sizing: border-box;
}

.vista-page {
	margin: 0;
	position: relative;
	min-height: 100vh;
	font-family: 'DM Sans', system-ui, sans-serif;
	color: #ffffff;
}

.vista-background {
	position: fixed;
	inset: 0;
	z-index: 0;
	background-image: url('/connect/auth/images/custom/vista/background.jpg');
	background-size: cover;
	background-position: center;
}

.vista-background::after {
	content: '';
	position: absolute;
	inset: 0;
	background-color: rgba(5, 55, 66, 0.6);
}

/* ---- White top bar ------------------------------------------------------ */
.vista-topbar {
	position: relative;
	z-index: 2;
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 24px;
	background: #ffffff;
	min-height: 90px;
	padding: 12px 32px;
	box-sizing: border-box;
}

.vista-topbar-brand {
	display: inline-flex;
	align-items: center;
}

.vista-topbar-brand img {
	height: 40px;
	width: auto;
}

.vista-topbar-brand__text {
	font-family: 'Quicksand', sans-serif;
	font-weight: 700;
	font-size: 28px;
	letter-spacing: 0.14em;
	color: var(--agent-primary, #2e7888);
	text-transform: uppercase;
}

.vista-topbar-notice {
	display: flex;
	align-items: center;
	gap: 16px;
	text-align: right;
	color: #053742;
	font-size: 14px;
	line-height: 1.5;
}

.vista-topbar-notice__title {
	font-size: 16px;
	line-height: 1.3;
	font-weight: 700;
	color: #053742;
	white-space: nowrap;
}

.vista-topbar-notice__body {
	max-width: 330px;
	padding-left: 16px;
	border-left: 1px solid #dcdcdc;
}

.vista-topbar-notice__body a {
	color: var(--agent-primary, #2e7888);
	text-decoration: underline;
}

/* ---- Centred card ------------------------------------------------------- */
.vista-content {
	position: relative;
	z-index: 2;
	min-height: calc(100vh - 90px);
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	padding: 48px 16px 96px;
}

.vista-card {
	width: 511px;
	max-width: 100%;
	border-radius: 16px;
	overflow: hidden;
}

/* ---- Tabs --------------------------------------------------------------- */
.vista-tabs {
	display: flex;
}

.vista-tab {
	flex: 1 1 0;
	border: none;
	cursor: pointer;
	font-family: inherit;
	font-weight: 700;
	font-size: 14px;
	padding: 12px 16px;
	background: #ffffff;
	color: var(--agent-text, #053742);
}

.vista-tab.is-active {
	background-color: color-mix(in srgb, var(--agent-primary, #2e7888) 55%, black);
	color: #ffffff;
}

/* Single (unavailable) header keeps the old full-width tab look. */
.vista-card-tab--single {
	background-color: color-mix(in srgb, var(--agent-primary, #2e7888) 55%, black);
	color: #ffffff;
	text-align: center;
	font-weight: 700;
	font-size: 14px;
	padding: 8px;
}

/* ---- Card body / panels ------------------------------------------------- */
.vista-card-body {
	background-color: color-mix(in srgb, var(--agent-primary, #2e7888) 55%, black);
	padding: 48px;
}

.vista-card-body[hidden] {
	display: none;
}

.vista-panel-title {
	text-align: center;
	font-size: 18px;
	line-height: 1.3;
	font-weight: 700;
	margin: 0 0 8px;
}

.vista-panel-intro {
	text-align: center;
	font-size: 14px;
	line-height: 1.5;
	margin: 0 0 24px;
}

.vista-card-body form {
	display: flex;
	flex-direction: column;
	gap: 16px;
}

.vista-form-row {
	display: flex;
	gap: 16px;
}

.vista-form-row .vista-form-group {
	flex: 1 1 0;
}

.vista-form-group {
	text-align: left;
}

.vista-form-group label {
	display: block;
	font-size: 12px;
	margin-bottom: 5px;
}

.vista-form-group input {
	width: 100%;
	box-sizing: border-box;
	background: #ffffff;
	color: #053742;
	border: 1px solid #dcdcdc;
	border-radius: 4px;
	padding: 12px 16px;
	font-size: 14px;
}

.vista-btn {
	width: 100%;
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 12px;
	background-color: var(--agent-primary, #2e7888);
	color: var(--agent-foreground, #ffffff);
	border: none;
	border-radius: 4px;
	padding: 12px 16px;
	font-family: inherit;
	font-size: 16px;
	font-weight: 700;
	cursor: pointer;
	text-decoration: none;
}

.vista-btn:hover {
	background-color: var(--agent-secondary, #416571);
}

.vista-btn img {
	width: 20px;
	height: 20px;
}

.vista-error-messages {
	margin-top: 4px;
}

.vista-alert {
	background-color: rgba(255, 255, 255, 0.9);
	color: #7a1010;
	border-radius: 4px;
	padding: 10px 14px;
	font-size: 13px;
	margin-bottom: 8px;
}

.vista-register-thanks {
	text-align: center;
	padding: 16px 0;
}

.vista-unavailable {
	text-align: center;
	font-size: 14px;
}

/* ---- Footer ------------------------------------------------------------- */
.vista-footer {
	position: fixed;
	bottom: 0;
	left: 0;
	right: 0;
	z-index: 2;
	display: flex;
	justify-content: space-between;
	align-items: center;
	padding: 24px;
	pointer-events: none;
}

.vista-footer-logos {
	display: flex;
	align-items: center;
	gap: 19px;
	pointer-events: auto;
}

.vista-footer-logos img {
	height: 40px;
	width: auto;
	max-width: 160px;
}

.vista-copyright {
	font-size: 14px;
	pointer-events: auto;
}

/* ---- Tablet ------------------------------------------------------------- */
@media (max-width: 1024px) {
	.vista-card {
		width: 90%;
	}

	.vista-card-body {
		padding: 32px;
	}

	.vista-topbar-notice__body {
		display: none;
	}
}

/* ---- Mobile ------------------------------------------------------------- */
@media (max-width: 520px) {
	.vista-topbar {
		flex-direction: column;
		align-items: flex-start;
		gap: 8px;
	}

	.vista-topbar-notice {
		text-align: left;
	}

	.vista-form-row {
		flex-direction: column;
		gap: 16px;
	}

	.vista-footer {
		flex-direction: column;
		gap: 8px;
		align-items: flex-start;
	}
}
