.sortable-list__list {
	display: flex;
	margin: 0;
	user-select: none;
}

.sortable-list.is-horizontal .sortable-list__list {
	flex-direction: row;
	flex-wrap: wrap;
}

.sortable-list.is-vertical .sortable-list__list {
	flex-direction: column;
}

.sortable-list__item {
	display: inline-block;

	&.is-active > * {
		box-shadow: 0 0 0 2px var(--studio-white), 0 0 0 4px var(--color-accent);
		z-index: z-index("root", ".sortable-list__item.is-draggable.is-active");
	}

	&.is-draggable.is-active {
		position: fixed;
	}

	&.is-shadow {
		filter: grayscale(100%);
		opacity: 0.5;
	}

	&.is-draggable > * {
		cursor: move;
		box-shadow: none;
	}
}

.sortable-list__navigation {
	margin-top: 18px;
	text-align: right;
}

.sortable-list__navigation-button {
	padding: 8px;
	background-color: var(--color-neutral-0);
	border: 1px solid var(--color-neutral-10);
	color: var(--color-neutral-light);

	&:not(:disabled):hover {
		cursor: pointer;
		color: var(--color-accent);
	}

	&:disabled {
		cursor: not-allowed;
		opacity: 0.4;
	}
}

.sortable-list.is-horizontal .sortable-list__navigation-button {
	display: inline-block;

	&.is-previous {
		padding-left: 12px;
		border-top-left-radius: 50%;
		border-bottom-left-radius: 50%;
	}

	&.is-next {
		margin-left: -1px;
		padding-right: 12px;
		border-top-right-radius: 50%;
		border-bottom-right-radius: 50%;
	}
}

.sortable-list.is-horizontal .sortable-list__navigation-button .gridicon {
	transform: rotate(90deg) translateX(1px);
}

.sortable-list.is-vertical .sortable-list__navigation-button {
	display: block;
	margin-left: auto;

	&.is-previous {
		border-top-right-radius: 50%;
		border-top-left-radius: 50%;
	}

	&.is-next {
		margin-top: -1px;
		border-bottom-right-radius: 50%;
		border-bottom-left-radius: 50%;
	}
}

.sortable-list.is-vertical .sortable-list__navigation-button .gridicon {
	transform: rotate(180deg) translateX(1px);
}
