/**
 * Archive pagination
 *
 * Shared by every filterable archive (courses, downloads). These rules used to
 * live in downloads-list.css, which is only enqueued on the downloads archive,
 * so the courses pager rendered unstyled.
 *
 * Styled to match the filter dropdowns above the results - same pill shape,
 * grey fill, and text treatment - so the two read as one set of controls.
 */

/* Sits below the results, centred in the container */
.downloads-pagination {
	width: 100%;
	margin: 1.5rem 0 2rem;
	display: flex;
	justify-content: center;
}

.plume-pagination {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: center;
	gap: 0.35rem;
}

/* Matches .plume-filter-container .dropdown-toggle: pill, #EFF1F1 fill, no
   border, 14px medium text. Sized down to suit a row of single digits. */
.plume-pagination .plume-page-link {
	min-width: 2.5rem;
	height: 2.5rem;
	padding: 0 0.75rem;
	border: 0;
	border-radius: 100px;
	background: #EFF1F1;
	color: #51596C;
	font-family: inherit;
	font-size: 14px;
	font-weight: 500;
	line-height: 1;
	box-shadow: none;
	cursor: pointer;
	transition: 0.35s;
}

.plume-pagination .plume-page-link:hover:not(:disabled):not(.is-current) {
	background: #E3E6E6;
	color: #833ba6;
	transition: 0.35s;
}

/* Keyboard focus needs to stay visible now the border has gone */
.plume-pagination .plume-page-link:focus-visible {
	outline: 2px solid #833ba6;
	outline-offset: 2px;
}

.plume-pagination .plume-page-link.is-current {
	background: #833ba6;
	color: #fff;
	font-weight: 700;
	cursor: default;
}

.plume-pagination .plume-page-link:disabled {
	opacity: 0.35;
	cursor: not-allowed;
}

/* The arrows carry a glyph rather than a label, so they read better square */
.plume-pagination .plume-page-prev,
.plume-pagination .plume-page-next {
	padding: 0;
	font-size: 18px;
}

.plume-pagination .plume-page-ellipsis {
	padding: 0 0.15rem;
	color: #51596C;
}

/* Phones fit fewer buttons, so tighten the gap and the padding */
@media (max-width: 767.98px) {
	.plume-pagination {
		gap: 0.25rem;
	}

	.plume-pagination .plume-page-link {
		min-width: 2.25rem;
		height: 2.25rem;
		padding: 0 0.5rem;
	}
}
