.lg-app {
	--ink: #172d35;
	--muted: #53666d;
	--accent: #146b56;
	--line: #dbe5e1;
	max-width: 1060px;
	margin: 24px auto;
	padding: clamp(16px, 4vw, 40px);
	background: #f5f8f3;
	color: var(--ink);
	font:
		16px/1.55 system-ui,
		-apple-system,
		BlinkMacSystemFont,
		'Segoe UI',
		sans-serif;
	border: 1px solid var(--line);
	border-radius: 24px;
	box-sizing: border-box;
}
.lg-app * {
	box-sizing: border-box;
}
.lg-app h2 {
	font-size: clamp(26px, 4vw, 38px);
	line-height: 1.2;
	margin: 26px 0 12px;
	letter-spacing: -0.03em;
}
.lg-app h3 {
	font-size: 22px;
	line-height: 1.35;
	margin: 12px 0;
}
.lg-app p {
	margin: 12px 0;
	white-space: pre-wrap;
	overflow-wrap: anywhere;
}
.lg-top {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
}
.lg-brand {
	font-size: 13px;
	font-weight: 800;
	letter-spacing: 0.12em;
}
.lg-app .lg-button,
.lg-app .lg-choice {
	font: inherit;
	cursor: pointer;
	min-height: 48px;
	border: 0;
	border-radius: 12px;
	padding: 12px 20px;
	background: var(--accent);
	color: #fff;
	font-weight: 650;
	text-align: center;
	line-height: 1.4;
	max-width: 100%;
	white-space: normal;
	overflow-wrap: anywhere;
}
.lg-app .lg-button.secondary {
	background: #fff;
	color: var(--ink);
	border: 1px solid var(--line);
}
.lg-app button:hover {
	filter: brightness(0.96);
}
.lg-app button:disabled {
	cursor: wait;
	opacity: 0.55;
}
.lg-app :focus-visible {
	outline: 3px solid #d17418;
	outline-offset: 3px;
}
.lg-app h2:focus {
	outline: none;
}
.lg-nav {
	display: flex;
	gap: 8px;
	flex-wrap: wrap;
	margin: 24px 0;
	border-bottom: 1px solid var(--line);
	padding-bottom: 18px;
}
.lg-nav .lg-button {
	flex: 1 0 auto;
	padding: 10px 12px;
}
.lg-muted,
.lg-eyebrow {
	color: var(--muted);
}
.lg-eyebrow {
	font-size: 13px;
	font-weight: 650;
}
.lg-hero {
	padding: clamp(24px, 4vw, 40px);
	border-radius: 18px;
	background: #193e35;
	color: #fff;
	margin: 28px 0;
	position: relative;
	overflow: hidden;
}
.lg-hero h3 {
	font-size: clamp(28px, 4vw, 40px);
	max-width: 540px;
	letter-spacing: -0.035em;
}
.lg-hero .lg-button {
	background: #d4ef81;
	color: #193e35;
	margin-top: 16px;
}
.lg-pill {
	display: inline-block;
	padding: 5px 12px;
	background: #e4eed7;
	color: #27482c;
	border-radius: 30px;
	font-size: 12px;
	font-weight: 750;
	text-transform: uppercase;
	letter-spacing: 0.06em;
}
.lg-stats {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 12px;
	margin: 24px 0;
}
.lg-stat {
	background: #fff;
	border: 1px solid var(--line);
	padding: 20px;
	border-radius: 14px;
	display: flex;
	flex-direction: column;
}
.lg-stat strong {
	font-size: 26px;
	line-height: 1.2;
}
.lg-stat span {
	margin-top: 8px;
	font-size: 13px;
	color: var(--muted);
	text-transform: capitalize;
}
.lg-actions {
	display: flex;
	flex-wrap: wrap;
	gap: 12px;
	margin: 24px 0;
}
.lg-card,
.lg-history,
.lg-question,
.lg-feedback {
	background: #fff;
	padding: 24px;
	border: 1px solid var(--line);
	border-radius: 16px;
	margin: 16px 0;
}
.lg-card .lg-button {
	margin: 8px 8px 0 0;
}
.lg-filters {
	display: grid;
	gap: 16px;
	margin: 24px 0;
}
.lg-app label {
	display: block;
	font-weight: 600;
}
.lg-app input,
.lg-app select {
	display: block;
	width: 100%;
	min-height: 50px;
	border: 1px solid #8fa7a0;
	border-radius: 10px;
	padding: 12px;
	background: #fff;
	color: var(--ink);
	font: inherit;
	margin: 8px 0 20px;
}
.lg-choices {
	display: grid;
	gap: 12px;
	margin: 24px 0;
}
.lg-app .lg-choice {
	text-align: left;
	color: var(--ink);
	background: #f7f9f6;
	border: 2px solid var(--line);
	min-height: 58px;
}
.lg-app .lg-choice[aria-pressed='true'] {
	border-color: var(--accent);
	background: #e0f1e6;
}
.lg-feedback.correct {
	background: #e8f5e9;
	border-color: #8cbe93;
	animation: lg-reveal 0.24s ease-out;
}
.lg-feedback.wrong {
	background: #fff5e5;
	border-color: #dab475;
}
.lg-reference {
	font-size: 22px;
	font-weight: 650;
}
.lg-enemy {
	padding: 14px;
	background: #eee8fa;
	border-radius: 10px;
}
.lg-error {
	padding: 16px;
	background: #fff0ed;
	border: 1px solid #b84b35;
	border-radius: 10px;
	color: #7c291a;
}
.lg-topic {
	display: grid;
	gap: 6px;
	margin: 20px 0;
}
.lg-app progress {
	width: 100%;
	height: 12px;
	accent-color: var(--accent);
}
.lg-app details {
	margin: 24px 0;
}
.lg-app summary {
	cursor: pointer;
	padding: 12px;
	min-height: 48px;
}
.lg-pill.weak {
	background: #f8ded9;
	color: #7c291a;
}
.lg-pill.learning {
	background: #fff0ca;
	color: #6b5108;
}
.lg-pill.mastered {
	background: #d9ebf9;
	color: #1a4a6b;
}
@media (min-width: 720px) {
	.lg-stats {
		grid-template-columns: repeat(4, minmax(0, 1fr));
	}
	.lg-filters {
		grid-template-columns: repeat(3, minmax(0, 1fr));
	}
	.lg-set-grid {
		display: grid;
		grid-template-columns: repeat(2, minmax(0, 1fr));
		gap: 16px;
	}
	.lg-set-grid .lg-card {
		margin: 0;
	}
	.lg-question {
		padding: 36px;
	}
	.lg-nav .lg-button {
		flex: none;
	}
}
@media (prefers-reduced-motion: reduce) {
	.lg-app * {
		animation: none !important;
		transition: none !important;
	}
}
@keyframes lg-reveal {
	from {
		transform: translateY(5px);
		opacity: 0.8;
	}
	to {
		transform: translateY(0);
		opacity: 1;
	}
}
