* {
	box-sizing: border-box;
}

body {
	margin: 0;
	min-height: 100vh;
	display: flex;
	flex-direction: column;
	padding: 2rem 1rem 0;
	background: var(--bg);
	color: var(--fg);
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.site-header {
	max-width: 40rem;
	width: 100%;
	margin: 0 auto 2rem;
}

.site-header h1 {
	margin: 0;
	padding: 0;
	font-family: 'Trebuchet MS', sans-serif;
	font-weight: normal;
	font-size: 2rem;
	color: var(--title-fg, var(--accent));
}

.site-header-top {
	display: flex;
	align-items: baseline;
	justify-content: space-between;
	gap: 1rem;
}

.share-links {
	display: flex;
	align-items: center;
	gap: 0.4rem;
	flex-shrink: 0;
	font-size: 0.8rem;
}

.share-label,
.share-separator {
	color: var(--muted);
}

.share-link {
	color: var(--link, var(--accent));
	text-decoration: none;
}

.share-link:hover {
	color: var(--fg);
	text-decoration: underline;
}

.site-description {
	margin: 0.35rem 0 0;
	font-size: 0.9rem;
	color: var(--muted);
}

.site-description h2 {
	margin: 0.75rem 0 0.35rem;
	font-size: 1rem;
	font-weight: 600;
	color: var(--fg);
}

.site-description h2:first-child {
	margin-top: 0;
}

.site-description p {
	margin: 1rem 0 0;
}

.site-description p:first-child {
	margin-top: 0;
}

.site-description ul {
	list-style-type: none;
	padding-left: 1rem;
	padding-top: 0.25rem;
	margin-top: 0.25rem;
}

.site-description a,
.site-description a:visited {
	color: var(--link, var(--accent));
	text-decoration: none;
}

.site-description a:hover {
	color: var(--fg);
}

.site-description tt.docutils.literal {
	padding: 0 1px;
	font-size: 0.95em;
	background-color: var(--code-bg, var(--border));
	color: var(--code-fg, var(--fg));
}

.roster {
	flex: 1 0 auto;
	max-width: 40rem;
	width: 100%;
	margin: 0 auto;
	display: flex;
	flex-direction: column;
	gap: 0.5rem;
}

.character {
	border: 1px solid var(--border);
	border-radius: 8px;
	overflow: hidden;
}

.character-row {
	display: flex;
	align-items: center;
}

.character-toggle {
	flex: 1;
	min-width: 0;
	display: flex;
	align-items: center;
	gap: 0.75rem;
	padding: 0.75rem 1rem;
	background-color: var(--card-bg);
	cursor: pointer;
}

.character-toggle:hover {
	background-color: var(--card-bg-hover);
}

.avatar {
	width: 48px;
	height: 48px;
	border-radius: 50%;
	object-fit: cover;
	flex-shrink: 0;
	background: var(--border);
}

.identity {
	display: flex;
	flex-direction: column;
	min-width: 0;
}

.name {
	font-size: 0.9rem;
	font-weight: 600;
}

.world {
	font-size: 0.8rem;
	color: var(--muted);
}

.toggle-indicator {
	flex-shrink: 0;
	margin-left: auto;
	color: var(--muted);
}

.toggle-indicator::before {
	content: "+";
}

.character-toggle[aria-expanded="true"] .toggle-indicator::before {
	content: "\2212";
}

.bio {
	padding: 1rem;
	border-top: 1px solid var(--border);
	background: var(--bio-bg);
	font-family: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;
	font-size: 0.85rem;
	color: var(--bio-fg);
}

/* Replace http log by a link to it on mobile. */
.bio-source-link {
	display: none;
}

.bio pre {
	margin: 0;
	white-space: pre-wrap;
	overflow-wrap: break-word;
	word-break: break-word;
	font: inherit;
	font-size: 10px;
}

.bio p {
	margin: 0.75rem 0 0;
}

.bio p:first-child {
	margin-top: 0;
}

.bio-footer {
	margin-top: 0.75rem;
	padding-top: 0.75rem;
	border-top: 1px dashed var(--bio-border);
	color: var(--bio-muted);
}

.bio-footer table {
	width: 100%;
	border-collapse: collapse;
	font-size: 0.7rem;
}

.bio-footer th,
.bio-footer td {
	text-align: left;
	font-weight: normal;
	padding: 0.15rem 0;
	vertical-align: top;
}

.bio-footer th {
	padding-right: 0.75rem;
	white-space: nowrap;
}

.bio-footer a {
	color: inherit;
	word-break: break-all;
}

.url-id,
.city-short {
	display: none;
}

.bio-footer tr.spacer td {
	padding: 0.75rem 0 0;
}

.empty {
	color: var(--muted);
	text-align: center;
}

.site-footer {
	flex-shrink: 0;
	margin-top: 3rem;
	padding: 1.5rem 1rem;
	border-top: 1px solid var(--border);
	color: var(--muted);
	font-size: 0.85rem;
}

.footer-inner {
	max-width: 40rem;
	width: 100%;
	margin: 0 auto;
	display: flex;
	align-items: center;
	justify-content: space-between;
}

.site-footer a {
	color: inherit;
	text-decoration: none;
}

.site-footer a:hover {
	text-decoration: underline;
}

.footer-separator {
	margin: 0 0.5rem;
}

@media (max-width: 640px) {
	body {
		min-height: 0;
	}

	.footer-inner {
		flex-direction: column;
		justify-content: center;
		gap: 0.5rem;
	}

	.footer-inner > span {
		padding-bottom: 0.5rem;
	}

	.footer-links {
		display: flex;
		flex-direction: column;
		align-items: center;
		gap: 0.5rem;
	}

	.footer-separator {
		display: none;
	}

	.bio pre {
		display: none;
	}

	.bio-footer th {
		white-space: normal;
	}

	.bio-source-link {
		display: inline-block;
		margin-top: 0.5rem;
		color: var(--link, var(--accent));
		font-size: 0.8rem;
		text-decoration: none;
	}

	.bio-source-link:hover {
		text-decoration: underline;

	.url-full,
	.city-full {
		display: none;
	}

	.url-id,
	.city-short {
		display: inline;
	}
}
