:root {
	--bg: #2b2b31;
	--fg: #e6e6e6;
	--muted: #8a8a94;
	--line: #3a3a42;
}

* {
	box-sizing: border-box;
}

html,
body {
	height: 100%;
	margin: 0;
}

body {
	background: var(--bg);
	color: var(--fg);
	font: 14px/1.4 system-ui, -apple-system, "Segoe UI", sans-serif;
	display: flex;
	flex-direction: column;
}

header {
	display: flex;
	align-items: center;
	gap: 12px;
	padding: 10px 16px;
	border-bottom: 1px solid var(--line);
	flex: 0 0 auto;
}

h1 {
	margin: 0;
	font-size: 15px;
	font-weight: 600;
	letter-spacing: 0.02em;
}

#search {
	flex: 0 1 320px;
	padding: 6px 10px;
	background: #232329;
	border: 1px solid var(--line);
	border-radius: 6px;
	color: var(--fg);
	outline: none;
}

#search:focus {
	border-color: #5a5a66;
}

#count {
	color: var(--muted);
	font-variant-numeric: tabular-nums;
}

#view {
	flex: 1 1 auto;
	overflow-y: auto;
	overflow-x: hidden;
	position: relative;
}

#spacer {
	position: relative;
	width: 100%;
}

#layer {
	position: absolute;
	inset: 0;
}

.cell {
	position: absolute;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: flex-start;
	padding-top: 10px;
	cursor: pointer;
	user-select: none;
}

.cell .icon {
	width: 64px;
	height: 64px;
	display: flex;
	align-items: center;
	justify-content: center;
}

.cell .icon svg,
.cell .icon img {
	width: 64px;
	height: 64px;
	display: block;
}

.cell .name {
	margin-top: 6px;
	font-size: 11px;
	color: var(--muted);
	max-width: 92px;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.cell:hover .name {
	color: var(--fg);
}
