/*
 * Matches the canadajob theme's established look (same color values as
 * style.css's :root — --red:#D3212C, --line:#E7E7E7, --red-tint:#FBEAEA —
 * redeclared locally rather than relying on the theme's custom properties,
 * since this plugin has to work regardless of which theme is active.
 */
.elc-quiz {
	--elc-red: #D3212C;
	--elc-red-tint: #FBEAEA;
	--elc-line: #E7E7E7;
	--elc-ink: #16181D;
	--elc-gray: #6B6F76;
	max-width: 620px;
	margin: 0 auto;
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
	color: var(--elc-ink);
}
.elc-quiz * { box-sizing: border-box; }

.elc-loading, .elc-empty, .elc-error-banner {
	text-align: center;
	padding: 40px 20px;
	color: var(--elc-gray);
}
.elc-error-banner { color: var(--elc-red); }

.elc-progress { margin-bottom: 20px; }
.elc-progress-bar {
	background: var(--elc-line);
	border-radius: 999px;
	height: 6px;
	overflow: hidden;
}
.elc-progress-fill {
	background: var(--elc-red);
	height: 100%;
	transition: width 0.25s ease;
}
.elc-progress-label {
	font-size: 12.5px;
	color: var(--elc-gray);
	margin-top: 8px;
	font-weight: 600;
}

.elc-card {
	background: #fff;
	border: 1px solid var(--elc-line);
	border-radius: 8px;
	padding: 32px;
}
@media (max-width: 480px) {
	.elc-card { padding: 22px; }
}

.elc-tab-title {
	font-size: 20px;
	font-weight: 700;
	margin: 0 0 20px;
	line-height: 1.3;
}

.elc-question { margin-bottom: 22px; }
.elc-question-label {
	display: block;
	font-size: 14.5px;
	font-weight: 600;
	margin-bottom: 10px;
}

.elc-options { display: flex; flex-direction: column; gap: 8px; }
.elc-option {
	display: flex;
	align-items: center;
	gap: 10px;
	border: 1px solid var(--elc-line);
	border-radius: 6px;
	padding: 12px 14px;
	cursor: pointer;
	font-size: 14.5px;
	transition: border-color 0.15s ease, background 0.15s ease;
}
.elc-option:hover { border-color: var(--elc-red); }
.elc-option input[type="radio"] { accent-color: var(--elc-red); flex: none; }
.elc-option:has(input:checked) {
	border-color: var(--elc-red);
	background: var(--elc-red-tint);
}

.elc-question input[type="text"],
.elc-question input[type="email"] {
	width: 100%;
	padding: 11px 14px;
	border: 1px solid var(--elc-line);
	border-radius: 6px;
	font-size: 14.5px;
	font-family: inherit;
	color: var(--elc-ink);
}
.elc-question input:focus { outline: 2px solid var(--elc-red); outline-offset: 1px; }

.elc-field-error, .elc-submit-error {
	color: var(--elc-red);
	font-size: 13px;
	margin: 6px 0 0;
	min-height: 0;
}
.elc-has-error .elc-option { border-color: var(--elc-red); }

.elc-nav {
	display: flex;
	justify-content: flex-end;
	gap: 10px;
	margin-top: 26px;
	padding-top: 20px;
	border-top: 1px solid var(--elc-line);
}

.elc-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	padding: 12px 24px;
	border-radius: 7px;
	font-size: 14.5px;
	font-weight: 600;
	border: 1px solid transparent;
	cursor: pointer;
	font-family: inherit;
}
.elc-btn:disabled { opacity: 0.6; cursor: default; }
.elc-btn-red { background: var(--elc-red); color: #fff; }
.elc-btn-red:hover:not(:disabled) { background: #b91c23; }
.elc-btn-outline { background: #fff; color: var(--elc-ink); border-color: var(--elc-line); margin-right: auto; }
.elc-btn-outline:hover { background: #fafafa; }

.elc-confirmation { text-align: center; padding: 48px 32px; }
.elc-confirmation-icon {
	width: 56px;
	height: 56px;
	border-radius: 50%;
	background: #EAFAF0;
	color: #1A9C53;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 26px;
	margin: 0 auto 18px;
}
.elc-confirmation h2 { margin: 0 0 10px; font-size: 20px; }
.elc-confirmation p { margin: 0; color: var(--elc-gray); font-size: 14.5px; line-height: 1.5; }
