/*
 * Health Wellness Quiz — layout and structure only.
 * Typography, colors, and button styling inherit from the active theme.
 * Subtle surfaces use theme-neutral gray rgba so the quiz blends into
 * both light and dark themes without overriding palette choices.
 */

.hwq-quiz {
	max-width: 48rem;
	margin: 0 auto;
	font: inherit;
	color: inherit;
}

.hwq-progress {
	position: relative;
	width: 100%;
	height: 0.35em;
	border-radius: 999em;
	background: rgba(127, 127, 127, 0.15);
	overflow: hidden;
	margin-bottom: 0.75em;
}

.hwq-progress-bar {
	position: absolute;
	inset: 0 auto 0 0;
	width: 0;
	background: currentColor;
	opacity: 0.85;
	transition: width 0.3s ease;
}

.hwq-step {
	margin: 0 0 1em;
	font-size: 0.9em;
	opacity: 0.7;
}

.hwq-stage {
	transition: opacity 0.14s ease;
}

.hwq-stage--leaving {
	opacity: 0;
}

.hwq-form {
	margin: 0;
}

.hwq-fieldset {
	border: 0;
	padding: 0;
	margin: 0;
}

.hwq-legend {
	display: block;
	width: 100%;
	font-size: 1.35em;
	line-height: 1.3;
	font-weight: 600;
	margin: 0 0 0.75em;
	padding: 0;
	outline: 0;
}

.hwq-help {
	margin: 0 0 1em;
	opacity: 0.75;
}

.hwq-options {
	list-style: none;
	padding: 0;
	margin: 0 0 1.25em;
	display: grid;
	gap: 0.5em;
	grid-template-columns: 1fr;
}

@media (min-width: 40rem) {
	.hwq-options--multi {
		grid-template-columns: 1fr 1fr;
	}
}

.hwq-option {
	margin: 0;
}

.hwq-option-button,
.hwq-option-label {
	display: block;
	width: 100%;
	text-align: left;
	padding: 0.75em 1em;
	border: 1px solid rgba(127, 127, 127, 0.45);
	border-radius: 0.4em;
	background: transparent;
	color: inherit;
	font: inherit;
	line-height: 1.4;
	cursor: pointer;
	transition: background-color 0.15s ease, border-color 0.15s ease, transform 0.05s ease;
}

.hwq-option-button:hover,
.hwq-option-label:hover,
.hwq-option-button:focus-visible,
.hwq-option-label:focus-within {
	background: rgba(127, 127, 127, 0.08);
	border-color: currentColor;
}

.hwq-option-button:active {
	transform: translateY(1px);
}

.hwq-option-label {
	display: flex;
	gap: 0.75em;
	align-items: flex-start;
}

.hwq-checkbox {
	flex: 0 0 auto;
	margin-top: 0.25em;
}

.hwq-option-text {
	flex: 1 1 auto;
}

.hwq-error {
	margin: 0 0 0.75em;
	font-size: 0.95em;
	color: #b32d2e;
}

.hwq-nav {
	display: flex;
	gap: 0.5em;
	flex-wrap: wrap;
	align-items: center;
}

.hwq-nav-back,
.hwq-nav-next,
.hwq-restart {
	font: inherit;
	color: inherit;
	padding: 0.6em 1.25em;
	border: 1px solid currentColor;
	border-radius: 0.4em;
	background: transparent;
	cursor: pointer;
}

.hwq-nav-next {
	margin-left: auto;
}

.hwq-nav-back:hover,
.hwq-nav-next:hover,
.hwq-restart:hover,
.hwq-nav-back:focus-visible,
.hwq-nav-next:focus-visible,
.hwq-restart:focus-visible {
	background: rgba(127, 127, 127, 0.1);
}

.hwq-loading {
	padding: 2em 0;
	text-align: center;
	opacity: 0.8;
}

/* Intro */

.hwq-intro {
	padding: 0.5em 0;
}

.hwq-intro-heading {
	margin: 0 0 0.5em;
	font-size: 1.45em;
	line-height: 1.25;
	outline: 0;
}

.hwq-intro-body {
	margin: 0 0 1.25em;
	font-size: 1.05em;
	max-width: 38em;
	opacity: 0.9;
}

.hwq-intro-actions {
	margin: 0;
}

.hwq-intro-start {
	font: inherit;
	color: inherit;
	padding: 0.7em 1.5em;
	border: 1px solid currentColor;
	border-radius: 0.4em;
	background: transparent;
	cursor: pointer;
	transition: background-color 0.15s ease;
}

.hwq-intro-start:hover,
.hwq-intro-start:focus-visible {
	background: rgba(127, 127, 127, 0.1);
}

/* Results */

.hwq-results-title {
	margin: 0 0 0.5em;
	outline: 0;
}

.hwq-results-intro {
	margin: 0 0 1.25em;
	font-size: 1.05em;
}

.hwq-coupon {
	padding: 0.9em 1em;
	margin: 0 0 1.5em;
	border: 1px dashed currentColor;
	border-radius: 0.4em;
	background: rgba(127, 127, 127, 0.06);
}

.hwq-coupon-text {
	margin: 0;
	font-size: 1.05em;
}

.hwq-coupon-code {
	display: inline-block;
	margin: 0 0.15em;
	padding: 0.1em 0.45em;
	border-radius: 0.25em;
	background: rgba(127, 127, 127, 0.18);
	font-weight: 700;
	font-family: inherit;
	letter-spacing: 0.02em;
}

.hwq-results-empty {
	margin: 0 0 1.25em;
	opacity: 0.85;
}

.hwq-products {
	list-style: none;
	padding: 0;
	margin: 0 0 1.5em;
	display: grid;
	gap: 1em;
	grid-template-columns: 1fr;
}

@media (min-width: 36rem) {
	.hwq-products {
		grid-template-columns: 1fr 1fr;
	}
}

@media (min-width: 60rem) {
	.hwq-products {
		grid-template-columns: repeat(3, 1fr);
	}
}

.hwq-product {
	display: flex;
	flex-direction: column;
	padding: 1em;
	border: 1px solid rgba(127, 127, 127, 0.35);
	border-radius: 0.5em;
	background: rgba(127, 127, 127, 0.03);
}

.hwq-product-image {
	display: block;
	margin: -1em -1em 0.75em;
	overflow: hidden;
	border-radius: 0.5em 0.5em 0 0;
}

.hwq-product-image img {
	display: block;
	width: 100%;
	height: auto;
}

.hwq-product-body {
	display: flex;
	flex-direction: column;
	flex: 1 1 auto;
}

.hwq-product-title {
	margin: 0 0 0.35em;
	font-size: 1.1em;
	line-height: 1.25;
}

.hwq-product-title a {
	color: inherit;
	text-decoration: none;
}

.hwq-product-title a:hover,
.hwq-product-title a:focus-visible {
	text-decoration: underline;
}

.hwq-product-description {
	margin: 0 0 0.75em;
	font-size: 0.95em;
	opacity: 0.9;
	flex: 1 1 auto;
}

.hwq-product-price {
	margin: 0 0 0.75em;
	font-weight: 600;
}

.hwq-product-missing {
	margin: 0;
	font-style: italic;
	opacity: 0.7;
}

.hwq-add-to-cart {
	align-self: flex-start;
}

.hwq-results-actions {
	margin: 1em 0 0;
	text-align: center;
}

@media (prefers-reduced-motion: reduce) {
	.hwq-stage,
	.hwq-progress-bar,
	.hwq-option-button,
	.hwq-option-label {
		transition: none;
	}
}
