I hope you might already be having media queries for different screens sizes. You can achieve the above using the following trick.
-Set a default CSS property for state-indicator(I have used z-index)
-Have media query code to set the property for different width.(Number of slides you want)
-Upon screen resize rebuild the carousel.
Please find below the fiddle for the same
.state-indicator { z-index: 7; }
@media all and (max-width: 768px) {
.state-indicator { z-index: 6; }
}
@media all and (max-width: 500px) {
.state-indicator { z-index: 5; }
}
@media all and (max-width: 350px) {
.state-indicator { z-index: 4; }
}
@media all and (max-width: 260px) {
.state-indicator { z-index: 3; }
}