.sidebar {
	float: left;
	position: static;
	width: 260px;
	.generate-spacing-rule(2,margin,right);

	@media only screen and (min-width: @categories-media-min-width) {
		.translate(0,0);
	}

	@media only screen and (max-width: @categories-media-max-width) {
		background: white;
		display: none !important;
		position: fixed;
		top: 0;
		left: 0;
		bottom: 0;
		width: 100vw;
		padding: 0;
		.translate3d(100%,0,0);
		overflow: hidden;
		z-index: 9999;
		&.active {
			display: block !important;
		}
	}
}



.sidebar__content {
	.translate3d(0,0,0);
	@media only screen and (max-width: @categories-media-max-width) {
		height: 100%;
		.transition(all 0.5s);
	}
}



.sidebar__content--filters {
	@media only screen and (max-width: @categories-media-max-width) and (min-width: 501px) {
		max-height: calc(~"100vh - 60px");
		overflow-y: auto;
		transform: translateZ(0);
		.sidebar__article__header {
			border-bottom: 1px solid @color-gray-9 !important;
			& > svg {
				display: none;
			}
		}
		.sidebar__article__content {
			> ul {
				position: static !important;
				.clear_fix;
				li {
					float: left;
					width: 50%;
					&:first-of-type,
					&:nth-of-type(2) {
						padding-top: 10px;
					}
				}
				> li {
					&.list--parent {
						&.active {
							width: 100%;
							padding-bottom: 0;
							& ~ li {
								padding-top: 0;
							}
						}
					}
					ul {
						position: static !important;
						.clear_fix;
						li {
							&:last-of-type {
								.generate-spacing-rule(1,padding,bottom);
								.generate-spacing-rule(2,padding,left);
								.generate-spacing-rule(3,padding,right);
							}
							&:nth-of-type(2) {
								.generate-spacing-rule(1,padding,top);
							}
							ul {
								margin: 0 !important;
                                background: @color-gray-10;
								li {
									float: none;
									width: 100%;
									padding-top: 0;
									&:nth-of-type(2) {
										padding-top: 0;
									}
									&:first-of-type {
										.generate-spacing-rule(1,padding,top);
									}
								}
							}
						}
					}
				}
			}
		}
	}

	@media only screen and (max-width: 500px) {
		h4 {
			& ~ div {
				> ul {
					position: static !important;
					li {
						float: none;
						width: 100%;
					}
					ul {
						position: static !important;
						background: @color-gray-10;
						> .list--parent {
							&:not(.active) {
								ul {
									margin-left: ~"calc(@{spacing-min} + 20px + (2 * @{spacing-step}))" !important;
									li {
										&:last-of-type {
											padding-bottom: 0;
										}
									}
								}
							}
						}
					}
				}
			}
		}
	}
}





.sidebar__content__footer {
	display: none;
	.generate-spacing-rule(1,padding,top);
	.generate-spacing-rule(1,padding,bottom);
	> ul {
		.center_nav;
		> li {
			.generate-spacing-rule(1,padding,right);
			&:last-of-type {
				padding: 0;
			}
			a {
				justify-content: center;
			}
		}
	}

	@media only screen and (max-width: @categories-media-max-width) {
		display: block;
	}

	@media only screen and (max-width: 500px) {
		.generate-spacing-rule(2,padding,all);
		> ul {
			> li {
				display: block;
				width: 100%;
				padding: 0;
				.generate-spacing-rule(1,padding,bottom);
				&:last-of-type {
					padding: 0;
				}
			}
		}
	}
}



.sidebar__article {
	border: 1px solid @color-gray-9;
	border-radius: @sidebar-border-radius;
	padding: 0 !important;
	.generate-spacing-rule(2,margin,bottom);
	@media only screen and (max-width: @categories-media-max-width) {
		border: 0;
		border-bottom: 1px solid @color-gray-9;
		border-radius: 0;
		margin: 0;
	}
}



.sidebar__article__header {
	color: @color-gray-3;
	display: flex;
	align-items: center;
	position: relative;
	.generate-spacing-rule(2,padding,all);
	@media only screen and (max-width: @categories-media-max-width) {
		color: @color-gray-3;
		border-radius: 0;
		display: block;
		.typography-lineheight(24px);
		.generate-spacing-rule(4,padding,top);
		.generate-spacing-rule(4,padding,bottom);
		.generate-spacing-rule(2,padding,left);
		.generate-spacing-rule(2,padding,right);
		.clear_fix;
	}
	&[data-sidebar-menu] {
		cursor: pointer;
		& ~ div {
			border: 0;
			display: none;
		}
		&.active {
			& ~ div {
				@media only screen and (max-width: @categories-media-max-width) {
					display: block;
				}
			}
		}
	}

	&.active {
		.sidebar__article__header__icon {
			transform: rotate(90deg) scale(-1,1);
		}

		& ~ .sidebar__article__content {
			@media only screen and (min-width: @categories-media-min-width) {
				border-top: 1px solid @color-gray-9;
				display: block !important;
			}

			@media only screen and (max-width: @categories-media-max-width) {
				&.sidebar__article__content--pages {
					.translate3d(105%, 0, 0);
				}
			}

			&.sidebar__article__content--slider {
				padding-bottom: ~"calc(10px + (@{spacing-min} + (2 * @{spacing-step})))";
				.generate-spacing-rule(1,padding,top);
				.generate-spacing-rule(2,padding,left);
				.generate-spacing-rule(2,padding,right);
				@media only screen and (max-width: @categories-media-max-width) {
					padding-bottom: ~"calc(10px + (@{spacing-min} + (2 * @{spacing-step})))";
				}
			}
		}
	}

	& ~ .sidebar__article__content {
		border-top: 1px solid @color-gray-9;
	}

	.sidebar__article__header__title {
		display: flex;
		flex: 1 0;
		.box-shadow(none);
	}

	.sidebar__article__header__icon {
		transform: rotate(90deg) scale(1);
		transition: 0.5s all cubic-bezier(0.215, 0.610, 0.355, 1.000);
		@media only screen and (max-width: @categories-media-max-width) {
			display: none;
		}
	}

	svg {
		stroke: @color-gray-7;
	}
}

.sidebar__article__content {
	@media only screen and (max-width: @categories-media-max-width) {
		border-bottom: 1px solid @color-gray-9;
	}

	ul {
		li {
			.generate-spacing-rule(2,padding,bottom);
			.generate-spacing-rule(2,padding,left);
			.generate-spacing-rule(2,padding,right);
			.clear_fix;

			&:first-of-type {
				.generate-spacing-rule(2,padding,top);
			}

			&.list--parent {
				&.active {
					padding: 0;
					&:first-of-type {
						.generate-spacing-rule(2,padding,top);
						ul {
							.generate-spacing-rule(2,margin,top);
							.generate-spacing-rule(2,margin,bottom);
						}
					}

					&:last-of-type {
						ul {
							border: 0;
							.generate-spacing-rule(2,margin,top);
						}
					}

					> .sidebar__counter {
						.generate-spacing-rule(2,margin,right);
					}

					> .checkbox,
					> .radio-button {
						.generate-spacing-rule(2,margin,left);
						& + label {
							margin-left: ~"calc((@{spacing-min} + (2 * @{spacing-step})) * 2 + 20px)";
						}
					}

					> ul {
						display: block !important;
					}

					ul {
						border-bottom: 1px solid @color-gray-9;
                        background: @color-gray-10;
						padding-left: 0;
						margin-left: 0;
						.generate-spacing-rule(2,margin,top);
						.generate-spacing-rule(2,margin,bottom);
						.sidebar__counter {
							color: @color-gray-6;
						}
						.list--parent {
							&:first-of-type {
								.generate-spacing-rule(1,padding,top);
							}
						}
						ul {
							margin: 0 !important;
							margin-left: ~"calc((@{spacing-min} + (2 * @{spacing-step})) * 2 + 20px)" !important;
							> li {
								padding-left: 0;
								&:first-of-type {
									.generate-spacing-rule(1,padding,top);
								}
							}
						}
					}
				}
			}

			a,
			label {
				color: @color-gray-3;
				text-overflow: ellipsis;
				white-space: nowrap;
				overflow: hidden;
			}


			> ul {
				li {
					.generate-spacing-rule(1,padding,bottom);
					.generate-spacing-rule(1,padding,right);
					.generate-spacing-rule(2,padding,right);
				}
			}
		}
	}
}



.sidebar__article__content--slider {
	border-top: 0;
	padding-bottom: ~"calc(10px + (@{spacing-min} + (2 * @{spacing-step})))";
	.generate-spacing-rule(1,padding,left);
	.generate-spacing-rule(1,padding,right);
	@media only screen and (max-width: @categories-media-max-width) {
		padding-bottom: ~"calc(10px + (@{spacing-min} + (2 * @{spacing-step})))";
	}
}



.sidebar__article__content--pages {
	@media only screen and (max-width: @categories-media-max-width) {
		background: white;
		border: 0;
		position: absolute;
		top: 0;
		left: 0;
		right: 0;
		bottom: 0;
		max-height: calc(~"100vh - 60px");
		.translate3d(0,0,0);
		.transition(all 0.5s);
	}
	.sidebar__counter {
		@media only screen and (max-width: @categories-media-max-width) {
			.typography-lineheight(24px);
		}
	}
	ul {
		li {
			position: relative;
			padding: 0;
			@media only screen and (max-width: @categories-media-max-width) {
				border-bottom: 1px solid @color-gray-9;
				position: static;
			}
			&:first-of-type {
				padding: 0;
			}
			&:last-of-type {
				li {
					&:last-of-type {
						border: 0;
					}
				}
			}
			a {
				display: block;
				.generate-spacing-rule(1,padding,top);
				.generate-spacing-rule(1,padding,bottom);
				.generate-spacing-rule(2,padding,left);
				.generate-spacing-rule(2,padding,right);
				.link--inherit;
				@media only screen and (max-width: @categories-media-max-width) {
					.typography-lineheight(24px);
					.generate-spacing-rule(4,padding,all);
					.clear_fix;
				}
				@media only screen and (min-width: @categories-media-min-width) {
					&.active {
						& + ul {
							display: block;
						}
					}
				}
			}
			> ul {
				border-top: 1px solid @color-gray-9;
				display: none;

				> li {
					padding: 0;
				}

				a {
					position: relative;
					.typography-rule(1,regular,false,@typography-base-size,24px);
					.generate-spacing-rule(1,padding,top);
					.generate-spacing-rule(1,padding,bottom);
					.generate-spacing-rule(2,padding,left);
					.generate-spacing-rule(2,padding,right);
					svg {
						stroke: @color-gray-7;
						float: left;
					}

				}

				@media only screen and (min-width: @categories-media-min-width) {
					li {
						&:last-of-type {
							border-bottom: 0;
						}
					}
				}

				@media only screen and (max-width: @categories-media-max-width) {
					background: white;
					border-top: 0;
					position: absolute;
					top: 0;
					left: 0;
					right: 0;
					bottom: 0;
					height: 100vh;
					max-height: calc(~"100vh - 60px");
					.translate3d(105%, 0, 0);
					.transition(all 0.5s);
					li {
						border-bottom: 1px solid @color-gray-9;
						position: relative;
					}
					a {
						.typography-lineheight(24px);
						.generate-spacing-rule(4,padding,top);
						.generate-spacing-rule(4,padding,bottom);
						.generate-spacing-rule(2,padding,left);
						.generate-spacing-rule(2,padding,right);
						.sidebar__counter {
							.typography-lineheight(24px);
						}
						> svg {
							display: none;
						}
					}
				}
			}
		}
	}
}



.sidebar__counter {
	color: @color-gray-7;
	float: right;
	.generate-spacing-rule(1,margin,left);
    .typography-rule(0);
}


.sidebar__mobile_icon {
	display: none;
	svg {
		stroke: @color-gray-3;
		display: block;
	}
	@media only screen and (max-width: @categories-media-max-width) {
		display: block;
		float: right;
	}
}