.election-widget {
	background: #f2f2f2;
	padding: 20px;
	font-family: "PT Sans", sans-serif;
	color: #000;
}

.election-widget[hidden] {
	display: none;
}

.election-widget__top {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 12px 20px;
	margin-bottom: 16px;
}

.election-widget__tabs {
	display: flex;
	background: #fff;
	border-radius: 20px;
	padding: 3px;
}

.election-widget__tab {
	border: 0;
	background: transparent;
	border-radius: 17px;
	padding: 8px 14px;
	font-family: inherit;
	font-size: 14px;
	font-weight: bold;
	text-transform: uppercase;
	color: #8a8a8a;
	cursor: pointer;
}

.election-widget__tab.is-active {
	background: #e81424;
	color: #fff;
}

.election-widget__status {
	font-size: 13px;
	color: #6b6b6b;
	flex: 1 1 auto;
}

.election-widget__stats {
	display: flex;
	gap: 18px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.election-widget__stats[hidden] {
	display: none;
}

.election-widget__stats li {
	border-left: 3px solid #e81424;
	padding-left: 8px;
	line-height: 1.25;
}

.election-widget__stats span {
	display: block;
	font-size: 13px;
}

.election-widget__stats strong {
	font-size: 15px;
}

.election-widget__cards {
	display: grid;
	grid-template-columns: repeat(8, minmax(0, 1fr));
	gap: 8px;
}

.election-widget__card {
	display: flex;
	flex-direction: column;
	align-items: center;
	background: #fff;
	padding: 12px 6px 14px;
	text-align: center;
	text-decoration: none;
	color: #000;
	min-height: 150px;
}

.election-widget__card:hover .election-widget__name,
.election-widget__card:hover .election-widget__count {
	color: #e81424;
}

.election-widget__place {
	display: flex;
	align-items: flex-end;
	justify-content: center;
	min-height: 2.3em;
	font-size: 13px;
	line-height: 1.15;
	margin-bottom: 8px;
}

.election-widget__photo {
	position: relative;
	width: 60px;
	height: 60px;
	border-radius: 50%;
	overflow: hidden;
	background: #e3e3e3 url("../img/election-silhouette.svg") center bottom / 70% no-repeat;
}

.election-widget__photo img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

.election-widget__percent {
	position: relative;
	margin-top: -9px;
	background: #e81424;
	color: #fff;
	font-size: 12px;
	font-weight: bold;
	border-radius: 9px;
	padding: 1px 6px;
}

.election-widget__name,
.election-widget__count {
	margin-top: 8px;
	font-size: 14px;
	font-weight: bold;
	line-height: 1.2;
}

.election-widget__count {
	font-size: 13px;
	white-space: nowrap;
}

.election-widget__name {
	display: flex;
	flex-direction: column;
	align-items: center;
	width: 100%;
}

.election-widget__initial {
	font-size: 13px;
	font-weight: normal;
}

.election-widget__surname {
	max-width: 100%;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

.election-widget__bottom {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	margin-top: 16px;
}

.election-widget__filter {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 8px;
	margin: 0;
}

.election-widget__label {
	font-size: 14px;
	font-weight: bold;
}

.election-widget__select {
	width: 130px;
	height: 34px;
	border: 1px solid #ccc;
	border-radius: 0;
	-webkit-appearance: none;
	-moz-appearance: none;
	appearance: none;
	background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 10 6'%3E%3Cpath d='M0 0l5 6 5-6z' fill='%23333'/%3E%3C/svg%3E") right 9px center / 10px 6px no-repeat;
	font-family: inherit;
	font-size: 14px;
	padding: 0 26px 0 6px;
	text-overflow: ellipsis;
	cursor: pointer;
}

.election-widget__select[hidden] {
	display: none;
}

.election-widget__select:disabled {
	background-color: #e3e3e3;
	opacity: .7;
	cursor: default;
}

.election-widget__more {
	display: inline-block;
	background: #e81424;
	color: #fff;
	font-size: 14px;
	font-weight: bold;
	text-transform: uppercase;
	text-decoration: none;
	padding: 9px 18px;
}

.election-widget__more:hover {
	background: #c91120;
	color: #fff;
}

.election-widget__source {
	margin: 12px 0 0;
	font-size: 12px;
	color: #6b6b6b;
}

.election-widget__source a {
	color: inherit;
	text-decoration: underline;
}

@media (max-width: 767px) {
	.election-widget {
		padding: 14px;
	}

	.election-widget__cards {
		display: flex;
		overflow-x: auto;
		scroll-snap-type: x mandatory;
		margin-right: -14px;
		padding-right: 14px;
	}

	.election-widget__card {
		flex: 0 0 104px;
		scroll-snap-align: start;
	}

	.election-widget__filter,
	.election-widget__select,
	.election-widget__more {
		width: 100%;
	}

	.election-widget__more {
		text-align: center;
	}
}
