/* Mobile Menus > Sidebar */
#sidr-main {
	display: block;
	position: fixed;
	top: 0;
	height: 100%;
	z-index: 999999;
	width: 300px;
	max-width: 100%;
	padding-bottom: 30px;
	overflow-x: hidden;
	overflow-y: auto;
	font-size: pem( 14 );
	background: #262626;
	color: #fff;
	-webkit-touch-callout: none;
	-webkit-user-select: none;
	-khtml-user-select: none;
	-moz-user-select: none;
	-ms-user-select: none;
	user-select: none;
	-webkit-overflow-scrolling: touch;

	&.right {
		right: -300px;
	}

	&.left {
		left: -300px;
	}

}

// Links
.sidr a {
	color: #707070;
}

.sidr a:hover,
.sidr-class-dropdown-toggle:hover,
.sidr-class-menu-item-has-children.active > a,
.sidr-class-menu-item-has-children.active > a > .sidr-class-dropdown-toggle {
	color: #fff;
	text-decoration: none;
}

// Close icon
a.sidr-class-toggle-sidr-close {
	position: relative;
	margin: 0 auto;
	display: block;
	height: 50px;
	line-height: 50px;
	font-size: 18px; // Use pixels because it's an icon
	color: #fff;
	background: rgba(0,0,0,0.1);
}

.sidr-class-toggle-sidr-close:before {
	content: "\f0c9"; //@todo change close to x "f00d"
	position: absolute;
	top: 0;
	left: 20px;
	height: 50px;
	line-height: 50px;
}

// Menu
.sidr-class-dropdown-menu {
	
	> li:first-child {
		border-top: 1px solid rgba( 255, 255, 255, 0.035 );
	}

	li {
		border-bottom: 1px solid rgba( 255, 255, 255, 0.035 );

		&:last-child {
			border: 0;
		}

		a {
			display: block;
			position: relative;
			padding: 12px 20px;

			&.sidr-class-sf-with-ul {
				padding-right: 40px;
			}

		}

		&.sidr-class-menu-item-has-children > a {
			padding-right: 60px;
		}

	}
	
	// Dropdowns
	ul {
		display: none;
		border-top: 1px solid rgba( 255, 255, 255, 0.035 );
		margin-left: 0;
		background: rgba(255,255,255,0.02);

		// Add arrows to sub-items
		a:before {
			content: "\f0da";
			display: inline-block;
			margin: 0 10px;
		}

		ul a:before {
			margin-left: 20px;
		}

		ul ul a:before {
			margin-left: 40px;
		}

	}

	// Dropdown arrows
	li.active > a > .sidr-class-dropdown-toggle:before {
		content: "\f078";
	}
	
	// Spacing for menu icons
	a {
	
		.fa {
			margin-right: 10px;

			body.rtl & {
				margin-right: 0;
				margin-left: 10px;
			}
		}

	}

}

.sidr-class-menu-item-has-children {
	position: relative;
}

.sidr-class-dropdown-toggle {
	font-size: 11px;
	height: 100%;
	width: 60px;
	position: absolute;
	right: 0;
	top: 0;
	cursor: pointer;
	color: #707070;
	padding-right: 20px; // @todo deprecate?
	text-align: center;

	&:before {
		content: "\f054";
		position: absolute;
		height: 30px;
		line-height: 30px;
		width: 30px;
		top: 50%;
		left: 50%;
		margin-top: -15px;
		margin-left: -15px;
	}

}

// Hide search and cart icons in sidr mobile menu
.sidr #searchform-header-replace-close,
.sidr .nav-arrow,
.sidr-class-wcmenucart,
.sidr-class-nav-arrow,
.sidr-class-search-toggle-li,
#sidr-id-searchform-dropdown {
	display: none !important;
}

// Sidebar overlay
.wpex-sidr-overlay {
	position: fixed;
	top: 0;
	left: 0;
	height: 100%;
	width: 100%;
	background: rgba(0,0,0,0.6);
	z-index: 9999;
}

// Sidebar Search
#sidr-id-searchform-overlay-title {
	display: none;
}

.sidr-class-mobile-menu-searchform {
	position: relative;
	margin: 30px 20px 0;
}

.sidr-class-mobile-menu-searchform {

	input {
		width: 100%;
		background: #fff;
		background: rgba(255,255,255,0.06);
		border: 0;
		outline: 0;
		padding: 15px 45px 15px 15px;
		line-height: 1.4em;
		color: #fff;
		color: rgba(255,255,255,0.5);
		font-size: 1em;
		font-weight: 400;
		@include transition( all 0.3s );
		@include border-radius( 3px );

		&:focus {
			color: #fff;
			color: rgba(255,255,255,0.5);
		}
	}

	button {
		background: none !important;
		display: block;
		position: absolute;
		right: 10px;
		height: 30px;
		line-height: 30px;
		width: 30px;
		text-align: center;
		top: 50%;
		margin-top: -15px;
		color: #fff;
		padding: 0;
		@include opacity( 0.4 );

		&:hover {
			@include opacity( 1 );
		}

	}
	
}
