/* Euforie Scan – huisstijl Euforie Online
 * Kleuren en lettertype aanpassen via de variabelen hieronder.
 */
.eus {
	--eus-navy: #081633;
	--eus-navy-2: #13244a;
	--eus-navy-line: #1f3363;
	--eus-green: #2ce582;
	--eus-green-text: #1b7a4a;
	--eus-soft: #edf4ff;
	--eus-white: #ffffff;
	--eus-line: #d3def2;
	--eus-line-strong: #c3d1ea;
	--eus-muted: #4a5878;
	--eus-muted-2: #6a7894;
	--eus-panel-muted: #9aa6c0;
	--eus-panel-dim: #7e8ba8;
	--eus-warn: #ffb4a8;
	--eus-font: 'Roboto', system-ui, -apple-system, 'Segoe UI', Arial, sans-serif;

	box-sizing: border-box;
	display: grid;
	grid-template-columns: minmax(300px, 380px) minmax(0, 1fr);
	grid-template-areas: 'panel main';
	max-width: 1280px;
	min-height: 760px;
	margin: 0 auto;
	background: var(--eus-white);
	color: var(--eus-navy);
	font-family: var(--eus-font);
	font-size: 17px;
	font-weight: 500;
	line-height: 1.5;
	border-radius: 24px;
	overflow: hidden;
	box-shadow: 0 0 0 1px var(--eus-line);
	scroll-margin-top: 24px;
}

.eus *,
.eus *::before,
.eus *::after {
	box-sizing: border-box;
}

.eus :where(p, h2, ul, li) {
	margin: 0;
	padding: 0;
}

.eus :where(ul) {
	list-style: none;
}

.eus :where(button, input) {
	font-family: inherit;
	font-size: inherit;
	letter-spacing: inherit;
}

.eus :focus-visible {
	outline: 3px solid var(--eus-green);
	outline-offset: 3px;
}

.eus [tabindex="-1"]:focus {
	outline: none;
}

/* ---------- Rapport-paneel ---------- */
.eus-panel {
	grid-area: panel;
	display: flex;
	flex-direction: column;
	gap: 26px;
	padding: 48px 36px;
	background: var(--eus-navy);
	color: var(--eus-white);
}

.eus-panel-title {
	font-size: 30px;
	font-weight: 900;
	line-height: 1.1;
}

.eus-panel-domain {
	margin-top: 4px;
	color: var(--eus-green);
	font-weight: 500;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.eus-group-head {
	display: flex;
	justify-content: space-between;
	align-items: baseline;
	padding-bottom: 8px;
	border-bottom: 1px solid var(--eus-navy-line);
	font-size: 15px;
	font-weight: 700;
	color: var(--eus-panel-muted);
}

.eus-group-grade {
	color: var(--eus-white);
	font-size: 17px;
	font-weight: 900;
}

.eus-item {
	display: flex;
	align-items: center;
	gap: 12px;
	min-height: 42px;
	color: var(--eus-panel-dim);
	transition: color 0.2s ease;
}

.eus-item.is-answered {
	color: var(--eus-white);
}

.eus-item.is-current {
	color: var(--eus-green);
}

.eus-item-label {
	flex: 1;
	min-width: 0;
}

.eus-meter {
	flex: none;
	display: inline-flex;
	gap: 4px;
}

.eus-meter span {
	width: 22px;
	height: 8px;
	border-radius: 2px;
	background: var(--eus-navy-line);
	transition: background-color 0.25s ease;
}

.eus-meter span.is-on {
	background: var(--eus-green);
}

.eus-status {
	flex: none;
	width: 78px;
	text-align: right;
	font-size: 13px;
	font-weight: 700;
}

.eus-status--good { color: var(--eus-green); }
.eus-status--mid { color: var(--eus-white); }
.eus-status--low { color: var(--eus-warn); }

/* ---------- Content ---------- */
.eus-main {
	grid-area: main;
	display: flex;
	min-width: 0;
	padding: clamp(28px, 5vw, 64px) clamp(24px, 5vw, 72px);
}

.eus-screen {
	display: flex;
	flex-direction: column;
	gap: 24px;
	width: 100%;
}

.eus-screen--start {
	justify-content: center;
}

.eus-label {
	display: flex;
	flex-wrap: wrap;
	gap: 4px 12px;
	font-size: 17px;
	font-weight: 700;
	color: var(--eus-green-text);
}

.eus-muted {
	color: var(--eus-muted-2);
}

.eus-title {
	max-width: 24ch;
	font-size: clamp(30px, 3.6vw, 46px);
	font-weight: 900;
	line-height: 1.08;
	letter-spacing: -0.01em;
	color: var(--eus-navy);
	text-wrap: balance;
}

.eus-title--xl {
	max-width: 18ch;
	font-size: clamp(36px, 5vw, 64px);
	line-height: 1.02;
	letter-spacing: -0.02em;
}

.eus-intro {
	max-width: 46ch;
	font-size: clamp(18px, 1.8vw, 21px);
	color: var(--eus-muted);
}

/* Startformulier */
.eus-start {
	display: flex;
	align-items: flex-end;
	gap: 12px;
	max-width: 700px;
}

.eus-field--grow {
	flex: 1;
}

/* Velden */
.eus-field label {
	display: block;
	margin-bottom: 8px;
	font-size: 15px;
	font-weight: 700;
	color: var(--eus-navy);
}

.eus-field input {
	display: block;
	width: 100%;
	height: 60px;
	margin: 0;
	padding: 0 18px;
	border: 2px solid var(--eus-line-strong);
	border-radius: 14px;
	background: var(--eus-white);
	color: var(--eus-navy);
	font-size: 18px;
	box-shadow: none;
}

.eus-field input::placeholder {
	color: #8a97b3;
}

.eus-field input:focus {
	border-color: var(--eus-navy);
	outline: none;
}

.eus-field input[aria-invalid="true"] {
	border-color: #d9463b;
}

.eus-fields {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 20px;
}

.eus-form {
	display: flex;
	flex-direction: column;
	gap: 16px;
	flex: 1;
}

.eus-note {
	font-size: 14px;
	color: var(--eus-muted);
}

.eus-error {
	padding: 12px 16px;
	border-radius: 12px;
	background: #fdecea;
	color: #b3261e;
	font-weight: 700;
}

.eus-hp {
	position: absolute !important;
	left: -9999px !important;
	width: 1px;
	height: 1px;
	overflow: hidden;
}

/* Vraagopties */
.eus-options {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 16px;
	margin-top: 8px;
}

.eus-option {
	display: flex;
	flex-direction: column;
	justify-content: space-between;
	align-items: flex-start;
	gap: 16px;
	min-height: 128px;
	margin: 0;
	padding: 22px 24px;
	border: 2px solid var(--eus-line);
	border-radius: 20px;
	background: var(--eus-white);
	color: var(--eus-navy);
	text-align: left;
	cursor: pointer;
	transition: border-color 0.15s ease, background-color 0.15s ease;
}

.eus-option:hover {
	border-color: var(--eus-line-strong);
	background: #f7faff;
}

.eus-option.is-active {
	border-color: var(--eus-navy);
	background: var(--eus-soft);
}

.eus-option .eus-meter span {
	background: #e1e9f7;
}

.eus-option .eus-meter span.is-on {
	background: var(--eus-green);
}

.eus-option-text {
	font-size: clamp(18px, 1.8vw, 22px);
	font-weight: 700;
	line-height: 1.25;
}

/* Knoppen */
.eus-nav {
	display: flex;
	justify-content: space-between;
	align-items: center;
	gap: 12px;
	margin-top: auto;
	padding-top: 16px;
}

.eus-nav--start {
	justify-content: flex-start;
}

.eus-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-height: 56px;
	margin: 0;
	padding: 0 30px;
	border: 2px solid transparent;
	border-radius: 999px;
	font-size: 17px;
	font-weight: 700;
	line-height: 1.2;
	white-space: nowrap;
	text-decoration: none;
	cursor: pointer;
	transition: background-color 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.eus-btn--green {
	background: var(--eus-green);
	color: var(--eus-navy);
}

.eus-btn--green:hover {
	background: var(--eus-navy);
	color: var(--eus-white);
}

.eus-start .eus-btn {
	height: 60px;
	border-radius: 14px;
}

.eus-btn--ghost {
	background: var(--eus-white);
	border-color: var(--eus-line-strong);
	color: var(--eus-navy);
}

.eus-btn--ghost:hover {
	border-color: var(--eus-navy);
}

/* Laden */
.eus-screen--loading {
	align-items: center;
	justify-content: center;
	text-align: center;
}

.eus-loader {
	display: flex;
	align-items: flex-end;
	gap: 8px;
	height: 120px;
}

.eus-loader span {
	width: 36px;
	height: calc(28px + var(--k) * 22px);
	border-radius: 6px 6px 0 0;
	background: var(--eus-soft);
	box-shadow: inset 0 0 0 2px var(--eus-line-strong);
	animation: eus-climb 1.6s ease-in-out infinite;
	animation-delay: calc(var(--k) * 0.18s);
}

@keyframes eus-climb {
	0%, 15% { background: var(--eus-soft); box-shadow: inset 0 0 0 2px var(--eus-line-strong); }
	30%, 65% { background: var(--eus-green); box-shadow: inset 0 0 0 2px var(--eus-green); }
	85%, 100% { background: var(--eus-soft); box-shadow: inset 0 0 0 2px var(--eus-line-strong); }
}

.eus-loading-text {
	font-size: 20px;
	font-weight: 700;
}

/* ---------- Uitslag ---------- */
.eus-screen--result {
	gap: 22px;
}

.eus-cards {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 20px;
}

.eus-card {
	display: flex;
	flex-direction: column;
	gap: 12px;
	padding: 22px 26px;
	border-radius: 24px;
	background: var(--eus-soft);
}

.eus-card-label {
	font-size: 17px;
	font-weight: 700;
	color: var(--eus-muted);
}

.eus-card-row {
	display: flex;
	align-items: flex-end;
	justify-content: space-between;
	gap: 16px;
}

.eus-grade {
	font-size: clamp(60px, 6.5vw, 80px);
	font-weight: 900;
	line-height: 0.9;
	letter-spacing: -0.03em;
	font-variant-numeric: tabular-nums;
}

.eus-bars {
	display: flex;
	align-items: flex-end;
	gap: 5px;
}

.eus-bar {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 24px;
	height: calc(22px + var(--k) * 16px);
	border-radius: 4px 4px 0 0;
	background: var(--eus-white);
	box-shadow: inset 0 0 0 2px var(--eus-line-strong);
	transition: background-color 0.3s ease, box-shadow 0.3s ease;
	transition-delay: calc(var(--k) * 90ms + 250ms);
}

.is-revealed .eus-bar.is-done {
	background: var(--eus-navy);
	box-shadow: inset 0 0 0 2px var(--eus-navy);
}

.is-revealed .eus-bar.is-current {
	background: var(--eus-green);
	box-shadow: inset 0 0 0 2px var(--eus-green);
}

.eus-goal {
	writing-mode: vertical-rl;
	transform: rotate(180deg);
	font-size: 11px;
	font-weight: 900;
	letter-spacing: 0.02em;
	line-height: 1;
	color: var(--eus-navy);
	white-space: nowrap;
}

.is-revealed .eus-bar.is-current .eus-goal {
	color: var(--eus-navy);
}

.eus-card-step {
	display: flex;
	flex-direction: column;
	gap: 3px;
	padding-top: 10px;
	border-top: 1px solid var(--eus-line);
}

.eus-card-stepnr {
	font-size: 13px;
	font-weight: 700;
	color: var(--eus-muted);
}

.eus-card-steptext {
	font-size: 16px;
	font-weight: 700;
	line-height: 1.3;
}

.eus-advice {
	align-self: flex-start;
	padding: 7px 14px;
	border-radius: 999px;
	background: var(--eus-navy);
	color: var(--eus-white);
	font-size: 14px;
	font-weight: 700;
}

.eus-lead {
	max-width: 44ch;
	font-size: clamp(18px, 1.8vw, 20px);
	color: var(--eus-muted);
}

.eus-lead strong {
	color: var(--eus-navy);
	font-weight: 700;
}

.eus-invite {
	max-width: 52ch;
	font-size: 18px;
	color: var(--eus-muted);
}

/* ---------- Kleinere schermen ---------- */
@media (max-width: 960px) {
	.eus {
		grid-template-columns: minmax(0, 1fr);
		grid-template-areas: 'main' 'panel';
		min-height: 0;
	}

	.eus-panel {
		padding: 32px 24px;
	}

	.eus-cards {
		grid-template-columns: minmax(0, 1fr);
	}
}

@media (max-width: 640px) {
	.eus {
		font-size: 16px;
		border-radius: 16px;
	}

	.eus-start {
		flex-direction: column;
		align-items: stretch;
	}

	.eus-options,
	.eus-fields {
		grid-template-columns: minmax(0, 1fr);
		gap: 12px;
	}

	.eus-option {
		min-height: 0;
		flex-direction: row-reverse;
		align-items: center;
		justify-content: space-between;
		padding: 18px 20px;
	}

	.eus-nav {
		flex-wrap: wrap;
	}

	.eus-nav .eus-btn {
		flex: 1;
		padding: 0 16px;
		white-space: normal;
	}

	.eus-nav--start .eus-btn {
		flex: 1 1 100%;
	}

	.eus-card {
		padding: 20px;
	}

	.eus-goal {
		font-size: 10px;
	}
}

@media (prefers-reduced-motion: reduce) {
	.eus-loader span {
		animation: none;
		background: var(--eus-green);
	}

	.eus-bars span,
	.eus-meter span,
	.eus-item {
		transition: none;
	}
}

/* ---------- Beschermen tegen themastijlen ----------
 * Sommige thema's verbergen koppen (animaties met opacity) of kleuren
 * invoervelden anders. Deze regels zetten dat binnen de scan terug.
 */
.eus .eus-title,
.eus .eus-label,
.eus .eus-intro,
.eus .eus-lead,
.eus .eus-invite,
.eus .eus-note,
.eus .eus-option-text,
.eus .eus-card-label,
.eus .eus-card-stepnr,
.eus .eus-card-steptext,
.eus .eus-grade,
.eus .eus-loading-text,
.eus .eus-panel-title,
.eus .eus-panel-domain,
.eus .eus-item,
.eus .eus-field label,
.eus .eus-btn {
	opacity: 1;
	visibility: visible;
	transform: none;
	animation: none;
	filter: none;
	clip-path: none;
	text-indent: 0;
}

.eus .eus-title,
.eus .eus-grade,
.eus .eus-option-text,
.eus .eus-card-steptext,
.eus .eus-loading-text,
.eus .eus-field label {
	color: var(--eus-navy);
	-webkit-text-fill-color: var(--eus-navy);
}

.eus .eus-panel-title,
.eus .eus-panel .eus-item.is-answered {
	color: var(--eus-white);
	-webkit-text-fill-color: var(--eus-white);
}

.eus .eus-field input,
.eus .eus-field input:focus {
	opacity: 1;
	color: var(--eus-navy);
	-webkit-text-fill-color: var(--eus-navy);
	text-shadow: none;
	background-image: none;
	text-transform: none;
	letter-spacing: normal;
}

.eus .eus-field input::placeholder {
	color: #8a97b3;
	-webkit-text-fill-color: #8a97b3;
	opacity: 1;
}

.eus .eus-btn,
.eus .eus-btn:hover,
.eus .eus-btn:focus {
	text-decoration: none;
	box-shadow: none;
}

.eus .eus-btn--green {
	color: var(--eus-navy);
	-webkit-text-fill-color: var(--eus-navy);
}

.eus .eus-btn--green:hover,
.eus .eus-advice {
	color: var(--eus-white);
	-webkit-text-fill-color: var(--eus-white);
}
