:root {
	color-scheme: dark;
	--bg: #0f141a;
	--panel: rgba(20, 27, 34, 0.82);
	--ink: #e6ebf0;
	--ink-2: #9aa7b4;
	--line: #2c3640;
	--accent: #ffb85c;
	font-family: system-ui, -apple-system, "Segoe UI", sans-serif;
	font-size: 13px;
}
html,
body {
	height: 100%;
	margin: 0;
	background: var(--bg);
	color: var(--ink);
	overflow: hidden;
}
#scene {
	position: fixed;
	inset: 0;
}
#scene canvas {
	display: block;
	width: 100%;
	height: 100%;
}
#scene .labels {
	position: absolute;
	inset: 0;
	pointer-events: none;
	overflow: hidden;
}
#hud {
	position: fixed;
	top: 12px;
	left: 12px;
	width: 300px;
	max-height: calc(100% - 24px);
	overflow: auto;
	background: var(--panel);
	border: 1px solid var(--line);
	border-radius: 6px;
	padding: 12px 14px;
	backdrop-filter: blur(6px);
}
#hud h1 {
	font-size: 17px;
	margin: 0 0 2px;
	letter-spacing: 0.01em;
}
#hud h2 {
	font-size: 11px;
	text-transform: uppercase;
	letter-spacing: 0.06em;
	color: var(--ink-2);
	margin: 14px 0 6px;
}
#status {
	color: var(--ink-2);
	font-variant-numeric: tabular-nums;
}
.row {
	display: flex;
	gap: 8px;
	align-items: center;
}
select,
button {
	font: inherit;
	color: var(--ink);
	background: #1b2229;
	border: 1px solid var(--line);
	border-radius: 4px;
	padding: 4px 8px;
}
button {
	cursor: pointer;
}
ul {
	margin: 0;
	padding: 0;
	list-style: none;
}
#characters li {
	display: flex;
	justify-content: space-between;
	gap: 8px;
	padding: 3px 0;
	cursor: pointer;
	font-variant-numeric: tabular-nums;
}
#characters li:hover,
#characters li.followed {
	color: var(--accent);
}
#characters .phase {
	color: var(--ink-2);
}
#log li {
	padding: 2px 0;
	color: var(--ink-2);
}
#log li b {
	color: var(--ink);
	font-weight: 500;
}
.hint {
	color: var(--ink-2);
	font-size: 11px;
}
footer {
	margin-top: 14px;
}
#banner {
	position: fixed;
	left: 50%;
	top: 16px;
	transform: translateX(-50%);
	background: var(--panel);
	border: 1px solid var(--line);
	border-radius: 6px;
	padding: 8px 14px;
	color: var(--accent);
}
/* labels placed by the CSS2D renderer */
.nameplate {
	font-size: 12px;
	font-weight: 600;
	color: var(--ink);
	text-shadow: 0 1px 2px rgba(0, 0, 0, 0.9), 0 0 6px rgba(0, 0, 0, 0.6);
	white-space: nowrap;
	user-select: none;
}
.nameplate.followed {
	color: var(--accent);
}
.bubble {
	max-width: 220px;
	background: rgba(255, 255, 255, 0.94);
	color: #1b2430;
	border-radius: 10px;
	padding: 5px 9px;
	font-size: 12px;
	line-height: 1.3;
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.35);
	user-select: none;
}
.bubble::after {
	content: "";
	position: absolute;
	left: 50%;
	bottom: -6px;
	transform: translateX(-50%);
	border: 6px solid transparent;
	border-bottom: 0;
	border-top-color: rgba(255, 255, 255, 0.94);
}
