/**
 * plugins/generic/browseByAuthor/styles/authorIndex.css
 *
 * Copyright (c) 2026 Marko Zakrajsek
 * Distributed under the GNU GPL v3. For full terms see the file LICENSE.
 *
 * Neutral styles for the author index. Kept at low specificity (:where) so a
 * theme can restyle any of it; for just the colour, set --author-index-accent.
 */

:where(.page_author_index) {
	--author-index-accent: #1e6292;
}

/* Letter pills */
:where(.page_author_index) .author_index_letters {
	display: flex;
	flex-wrap: wrap;
	gap: 0.5rem;
	margin: 1.5rem 0 2rem;
}

:where(.page_author_index) .author_index_letters a {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 2.25rem;
	height: 2.25rem;
	padding: 0 0.75rem;
	border: 1px solid var(--author-index-accent);
	border-radius: 999px;
	color: var(--author-index-accent);
	font-weight: 600;
	text-decoration: none;
}

:where(.page_author_index) .author_index_letters a:hover,
:where(.page_author_index) .author_index_letters a:focus-visible {
	box-shadow: 0 1px 4px rgba(0, 0, 0, 0.15);
}

:where(.page_author_index) .author_index_letters a:focus-visible {
	outline: 2px solid var(--author-index-accent);
	outline-offset: 2px;
}

:where(.page_author_index) .author_index_letters a.current {
	background: var(--author-index-accent);
	color: #fff;
}

:where(.page_author_index) .author_index_list {
	list-style: none;
	padding-left: 0;
	columns: 2;
}

:where(.page_author_index) .author_index_list li {
	break-inside: avoid;
}

:where(.page_author_index) .author_index_count {
	opacity: 0.7;
}

@media (max-width: 767px) {
	:where(.page_author_index) .author_index_list {
		columns: 1;
	}
}
