/*
 * Unresolved Gaps / GPS front-end assessment styles.
 *
 * IMPORTANT: this widget must look correct regardless of the host theme,
 * including dark themes. Every rule is scoped under #ug-assessment-root
 * (ID selector, so it never affects the rest of the site) and explicit
 * color/background values are used throughout — including !important on
 * text color and backgrounds — because relying on inheritance alone is
 * exactly what caused the original bug: dark-theme sites supply their own
 * text/background colors at high specificity, and the assessment container
 * had no background of its own, so text quietly inherited a dark color
 * against a dark page background almost everywhere except the one box
 * (.ug-disclaimer) that happened to already set an explicit background.
 * Every element below now gets the same explicit treatment.
 */

#ug-assessment-root {
	max-width: 640px;
	margin: 0 auto;
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
	background: #ffffff !important;
	color: #1a1a1a !important;
	border-radius: 10px;
	box-shadow: 0 1px 6px rgba(0, 0, 0, 0.12);
	line-height: 1.5;
}

#ug-assessment-root * {
	box-sizing: border-box;
}

#ug-assessment-root .ug-state {
	padding: 24px 20px;
	background: #ffffff !important;
}

#ug-assessment-root .ug-title,
#ug-assessment-root h2,
#ug-assessment-root h3 {
	color: #1a1a1a !important;
	font-weight: 600;
}

#ug-assessment-root .ug-title {
	font-size: 1.4rem;
	margin: 0 0 12px;
}

#ug-assessment-root h3 {
	font-size: 1.05rem;
	margin: 20px 0 6px;
}

#ug-assessment-root p {
	color: #333333 !important;
	margin: 0 0 12px;
}

#ug-assessment-root .ug-loading,
#ug-assessment-root .ug-error {
	text-align: center;
	padding: 40px 16px;
	font-size: 1rem;
	color: #333333 !important;
}

#ug-assessment-root .ug-error {
	color: #a5303a !important;
}

#ug-assessment-root .ug-disclaimer,
#ug-assessment-root .ug-disclaimer-final {
	font-size: 0.85rem;
	color: #444444 !important;
	background: #f6f6f7 !important;
	border-left: 3px solid #ccc;
	padding: 10px 14px;
	margin: 12px 0;
}

#ug-assessment-root .ug-consent-row {
	display: flex;
	align-items: flex-start;
	gap: 8px;
	margin: 16px 0;
	font-size: 0.9rem;
	color: #1a1a1a !important;
	background: #ffffff !important;
}

#ug-assessment-root .ug-consent-row span {
	color: #1a1a1a !important;
}

#ug-assessment-root .ug-consent-row input {
	margin-top: 4px;
	flex-shrink: 0;
}

#ug-assessment-root .ug-btn {
	display: inline-block;
	padding: 10px 20px;
	font-size: 1rem;
	border-radius: 6px;
	border: 1px solid #ccc;
	background: #ffffff !important;
	color: #1a1a1a !important;
	cursor: pointer;
}

#ug-assessment-root .ug-btn:disabled {
	opacity: 0.5;
	cursor: not-allowed;
}

#ug-assessment-root .ug-btn-primary {
	background: #1d4ed8 !important;
	color: #ffffff !important;
	border-color: #1d4ed8;
}

#ug-assessment-root .ug-btn-primary:hover:not(:disabled) {
	background: #1a3fb0 !important;
}

#ug-assessment-root .ug-progress-bar {
	background: #e5e5e5;
	border-radius: 4px;
	height: 8px;
	overflow: hidden;
	margin-bottom: 6px;
}

#ug-assessment-root .ug-progress-fill {
	background: #1d4ed8;
	height: 100%;
	transition: width 0.3s ease;
}

#ug-assessment-root .ug-progress-label {
	font-size: 0.8rem;
	color: #666666 !important;
	margin: 0 0 20px;
}

#ug-assessment-root .ug-question {
	border: none;
	padding: 0;
	margin: 0 0 24px;
	background: #ffffff !important;
}

#ug-assessment-root .ug-question legend {
	font-weight: 600;
	margin-bottom: 10px;
	padding: 0;
	color: #1a1a1a !important;
	background: #ffffff !important;
}

#ug-assessment-root .ug-option {
	display: flex;
	align-items: flex-start;
	gap: 8px;
	padding: 8px 0;
	cursor: pointer;
	color: #1a1a1a !important;
	background: #ffffff !important;
}

#ug-assessment-root .ug-option span {
	color: #1a1a1a !important;
}

#ug-assessment-root .ug-question textarea,
#ug-assessment-root .ug-question input[type="text"] {
	width: 100%;
	padding: 10px;
	border: 1px solid #ccc;
	border-radius: 6px;
	font-size: 1rem;
	background: #ffffff !important;
	color: #1a1a1a !important;
}

#ug-assessment-root .ug-transition {
	padding: 30px 10px;
	text-align: center;
	background: #ffffff !important;
}

#ug-assessment-root .ug-transition-text {
	font-size: 1.15rem;
	font-style: italic;
	color: #333333 !important;
	line-height: 1.6;
	max-width: 480px;
	margin: 0 auto;
}

#ug-assessment-root .ug-nav {
	display: flex;
	justify-content: space-between;
	gap: 12px;
	margin-top: 24px;
}

#ug-assessment-root .ug-nav .ug-btn-primary {
	margin-left: auto;
}

#ug-assessment-root .ug-inline-error {
	color: #a5303a !important;
	font-size: 0.9rem;
	margin-top: 12px;
}

#ug-assessment-root .ug-field-label {
	display: block;
	margin-bottom: 16px;
	font-weight: 600;
	color: #1a1a1a !important;
	background: #ffffff !important;
}

#ug-assessment-root .ug-field-label input {
	width: 100%;
	padding: 10px;
	border: 1px solid #ccc;
	border-radius: 6px;
	font-size: 1rem;
	font-weight: normal;
	margin-top: 4px;
	background: #ffffff !important;
	color: #1a1a1a !important;
}

#ug-assessment-root .ug-report-summary {
	color: #1a1a1a !important;
	font-size: 1.05rem;
}

#ug-assessment-root .ug-welcome-message,
#ug-assessment-root .ug-closing-message {
	color: #333333 !important;
	background: #ffffff !important;
	font-size: 1rem;
}

#ug-assessment-root .ug-closing-title {
	color: #1a1a1a !important;
}

#ug-assessment-root .ug-report-grid {
	display: grid;
	grid-template-columns: 1fr;
	gap: 8px;
	background: #f6f6f7 !important;
	padding: 14px;
	border-radius: 8px;
	margin: 16px 0;
	font-size: 0.9rem;
	color: #1a1a1a !important;
}

#ug-assessment-root .ug-report-grid div {
	color: #1a1a1a !important;
}

#ug-assessment-root .ug-note {
	font-size: 0.85rem;
	color: #555555 !important;
	font-weight: normal;
}

#ug-assessment-root .ug-closing-cta {
	text-align: center;
	margin: 24px 0;
}

#ug-assessment-root .ug-closing-cta .ug-btn-primary {
	text-decoration: none;
	padding: 12px 28px;
	font-weight: 600;
}

#ug-assessment-root .ug-report-grid strong {
	color: #1a1a1a !important;
}

/* Strengths / Blind Spots / Responsibility / First Honest Step / Recommended
   Learning Path are plain <h3>/<p> pairs inside .ug-report — covered by the
   general h3/p rules above, but repeated here explicitly since this is
   exactly the content the visibility issue was reported against. */
#ug-assessment-root .ug-report h3,
#ug-assessment-root .ug-report p {
	color: #1a1a1a !important;
	background: #ffffff !important;
}

#ug-assessment-root .ug-rhythm-list {
	padding-left: 20px;
	color: #1a1a1a !important;
	background: #ffffff !important;
}

#ug-assessment-root .ug-rhythm-list li {
	margin-bottom: 8px;
	color: #1a1a1a !important;
}

#ug-assessment-root .ug-rhythm-list strong {
	color: #1a1a1a !important;
}

@media (min-width: 480px) {
	#ug-assessment-root .ug-report-grid {
		grid-template-columns: 1fr 1fr;
	}
}
