.young-boundary {
	padding: clamp(1.1rem, 3vw, 1.6rem);
	border: 1px solid rgba(110, 231, 216, 0.28);
	border-radius: var(--radius-lg);
	background: linear-gradient(135deg, rgba(110, 231, 216, 0.06), transparent 58%);
}

.young-lab {
	margin-top: 1.5rem;
}

.interaction-sound-control {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 1rem;
	margin-top: 1rem;
	padding: 0.9rem 1rem;
	border: 1px solid rgba(110, 231, 216, 0.3);
	border-radius: var(--radius-md);
	background: rgba(110, 231, 216, 0.045);
}

.interaction-sound-control[hidden] {
	display: none;
}

.interaction-sound-control strong,
.interaction-sound-control span {
	display: block;
}

.interaction-sound-control span {
	margin-top: 0.2rem;
	color: var(--muted);
	font-size: 0.9rem;
}

.young-lab__picker .path-card {
	display: flex;
	flex-direction: column;
}

.young-lab__picker .path-card .button {
	width: 100%;
	margin-top: auto;
}

.young-lab__stage {
	padding: clamp(1.1rem, 4vw, 2rem);
	border: 1px solid rgba(168, 146, 255, 0.34);
	border-radius: var(--radius-lg);
	background:
		linear-gradient(145deg, rgba(168, 146, 255, 0.08), transparent 58%),
		var(--panel);
	box-shadow: var(--shadow);
}

.young-lab__stage-header {
	display: flex;
	align-items: start;
	justify-content: space-between;
	gap: 1rem;
	padding-bottom: 1rem;
	border-bottom: 1px solid var(--line);
}

.young-guide {
	display: flex;
	align-items: center;
	gap: 0.9rem;
	margin: 1rem 0;
	padding: 0.85rem 1rem;
	border: 1px solid var(--line-strong);
	border-radius: var(--radius-md);
	background: rgba(168, 146, 255, 0.055);
}

.young-guide[hidden] {
	display: none;
}

.young-guide p,
.young-guide p span {
	display: block;
	margin: 0;
}

.young-guide p span {
	margin-top: 0.2rem;
	color: var(--muted);
}

.young-guide__computer {
	position: relative;
	flex: 0 0 auto;
	width: 4rem;
	padding-top: 0.42rem;
}

.young-guide__antenna {
	position: absolute;
	top: 0;
	left: 50%;
	width: 0.14rem;
	height: 0.7rem;
	background: currentColor;
	transform: translateX(-50%);
}

.young-guide__antenna::before {
	position: absolute;
	top: -0.18rem;
	left: 50%;
	width: 0.42rem;
	aspect-ratio: 1;
	border-radius: 50%;
	background: currentColor;
	content: "";
	transform: translateX(-50%);
}

.young-guide__screen {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 0.65rem;
	width: 4rem;
	height: 2.75rem;
	border: 2px solid currentColor;
	border-radius: 0.7rem;
	background: rgba(7, 10, 18, 0.52);
	box-shadow: inset 0 0 1.1rem rgba(110, 231, 216, 0.11);
}

.young-guide__eye {
	width: 0.34rem;
	aspect-ratio: 1;
	border-radius: 50%;
	background: currentColor;
}

.young-guide__mouth {
	position: absolute;
	top: 2rem;
	left: 50%;
	width: 0.9rem;
	height: 0.32rem;
	border-bottom: 2px solid currentColor;
	border-radius: 0 0 50% 50%;
	transform: translateX(-50%);
}

.young-guide__base {
	display: block;
	width: 2.7rem;
	height: 0.35rem;
	margin: 0.18rem auto 0;
	border-radius: 999px;
	background: currentColor;
}

.young-guide[data-state="strong"] {
	border-color: rgba(110, 231, 216, 0.48);
	color: var(--teal);
	background: rgba(110, 231, 216, 0.075);
}

.young-guide[data-state="strong"] .young-guide__computer {
	animation: young-guide-celebrate 420ms ease-out;
}

.young-guide[data-state="retry"] {
	border-color: rgba(255, 122, 89, 0.44);
	color: var(--coral-soft);
	background: rgba(255, 122, 89, 0.06);
}

.young-guide[data-state="retry"] .young-guide__computer {
	animation: young-guide-consider 420ms ease-out;
}

.young-guide[data-state="retry"] .young-guide__mouth {
	height: 0.2rem;
	border-bottom: 0;
	border-top: 2px solid currentColor;
	border-radius: 50% 50% 0 0;
}

@keyframes young-guide-celebrate {
	0%, 100% { transform: translateY(0) rotate(0); }
	45% { transform: translateY(-0.42rem) rotate(3deg); }
	70% { transform: translateY(-0.16rem) rotate(-2deg); }
}

@keyframes young-guide-consider {
	0%, 100% { transform: rotate(0); }
	35% { transform: rotate(-5deg); }
	70% { transform: rotate(4deg); }
}

.young-lab__mission-name {
	margin: 0.25rem 0 0;
	color: var(--text);
	font-weight: 800;
}

.young-mission__intro {
	margin: 1.4rem 0;
}

.young-mission__intro h3 {
	margin-bottom: 0.45rem;
	font-size: clamp(1.55rem, 4vw, 2.35rem);
}

.young-mission__fiction {
	padding: 0.75rem 0.9rem;
	border-left: 3px solid var(--violet);
	background: rgba(168, 146, 255, 0.06);
	color: var(--muted);
}

.young-lab .mini-game__round {
	padding: clamp(1rem, 3vw, 1.4rem);
	border: 1px solid var(--line);
	border-radius: var(--radius-md);
	background: rgba(255, 255, 255, 0.02);
}

.young-lab .mini-game__round legend {
	width: 100%;
}

.young-lab .mini-game__round legend span {
	display: block;
	margin-bottom: 0.35rem;
	color: var(--violet);
	font-family: "Cascadia Code", "SFMono-Regular", Consolas, monospace;
	font-size: 0.72rem;
	font-weight: 800;
	letter-spacing: 0.08em;
	text-transform: uppercase;
}

.young-lab blockquote {
	margin: 0 0 1rem;
	padding: 1rem;
	border-left: 3px solid var(--violet);
	border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
	background: rgba(168, 146, 255, 0.06);
	color: var(--text);
}

.young-lab__prompt {
	color: var(--text);
	font-weight: 760;
}

.young-lab__completion {
	margin-top: 1.5rem;
	padding: clamp(1.1rem, 4vw, 1.8rem);
	border: 1px solid rgba(110, 231, 216, 0.4);
	border-radius: var(--radius-md);
	background: linear-gradient(140deg, rgba(110, 231, 216, 0.09), rgba(168, 146, 255, 0.04));
}

.young-lab__completion h3 {
	margin-bottom: 0.55rem;
}

.young-fallback {
	margin-top: 1.5rem;
	padding: clamp(1.1rem, 4vw, 1.8rem);
	border: 1px solid var(--line);
	border-radius: var(--radius-lg);
	background: var(--panel);
}

.young-fallback details {
	padding: 0.9rem 0;
	border-top: 1px solid var(--line);
}

.young-fallback details:last-child {
	border-bottom: 1px solid var(--line);
}

.young-fallback summary {
	min-height: 2.75rem;
	color: var(--text);
	font-weight: 800;
	cursor: pointer;
}

html[data-theme="light"] .young-boundary,
html[data-theme="light"] .young-lab__stage,
html[data-theme="light"] .young-fallback {
	background-color: var(--panel-solid);
}

@media (max-width: 45rem) {
	.interaction-sound-control {
		align-items: stretch;
		flex-direction: column;
	}

	.interaction-sound-control .button {
		width: 100%;
	}

	.young-lab__stage-header {
		align-items: stretch;
		flex-direction: column;
	}

	.young-lab__stage-header .button,
	.young-lab .mini-game__actions .button {
		width: 100%;
	}
}

@media (prefers-reduced-motion: reduce) {
	.young-guide[data-state] .young-guide__computer {
		animation: none;
	}
}

@media (forced-colors: active) {
	.young-boundary,
	.interaction-sound-control,
	.young-guide,
	.young-lab__stage,
	.young-lab .mini-game__round,
	.young-lab__completion,
	.young-fallback {
		border: 1px solid CanvasText;
	}

	.young-guide__screen,
	.young-guide__mouth {
		border-color: CanvasText;
	}

	.young-guide__antenna,
	.young-guide__antenna::before,
	.young-guide__eye,
	.young-guide__base {
		background: CanvasText;
	}
}
