#app-navigation > ul {
	height: auto;
	overflow-y: hidden;
}

.navigation a > span {
	display: inline-block;
	vertical-align: text-bottom;
	margin-right: 12px;
}

#app-navigation h3 {
	padding-top: 28px;
	padding-left: 12px;
	border-top: 1px solid #ededed;
}
#app-navigation h3 [class^='icon-'] {
	display: inline-block;
	vertical-align: sub;
}

#app-content {
	transition: transform 0.5s ease;
	transform: none;
}

.mobile-nav {
	padding: 12px;
	display: none;
}

.mobile-nav .toggle-menu {
	display: inline-block;
}

@media only screen and (max-width: 768px) {
	.mobile-nav-open #app-content {
		transform: translate(250px, 0);
	}

	.mobile-nav {
		display: block;
	}
}

.add-bookmark input {
	width: 100%;
	margin: 0;
	margin-bottom: 4px;
	padding: 12px 40px 12px 12px;
	box-sizing: border-box;
	background-color: transparent;
	border: none;
	border-bottom: 1px solid #eee;
	border-radius: 0;
}

.add-bookmark button {
	position: absolute;
	right: 0;
	top: 0;
	min-height: 34px;
	padding: 10px 20px;
	background-color: transparent;
	border: none;
	opacity: 0.5;
	font-weight: bold;
}

.bulk-actions {
	display: none;
	position: fixed;
	top: 45px;
	left: 250px;
	right: 0;
	box-shadow: 2px 1px 4px 0px #666;
	padding: 12px 20px;
	background: white;
	z-index: 3;
}

.bulk-actions + * {
	transition: margin-top 0.5s ease;
}

.bulk-actions.active {
	display: block;
}

.bulk-actions.active + * {
	margin-top: 100px;
}

@media only screen and (max-width: 768px) {
	.bulk-actions {
		position: relative;
		top: 0;
		right: 0;
		bottom: 0;
		left: 0;
	}

	.bulk-actions.active + * {
		margin-top: 0 !important;
	}
}

.bulk-actions > button {
	vertical-align: top;
}

.bulk-actions .tags {
	display: inline-block;
	width: 60%;
	margin: 3px 3px 3px 0;
	position: relative;
}

.bulk-actions .tags-selection {
	display: block;
	width: 100%;
}

.bulk-actions .selection-tools {
	float: right;
}

.bulk-actions .selection-tools .close {
	display: inline-block;
	cursor: pointer;
	margin: 3px 3px 3px 0;
	padding: 6px 12px;
	width: auto;
	min-height: 34px;
	cursor: pointer;
	box-sizing: border-box;
}

.bulk-actions .selection-tools .close span {
	display: inline-block;
	vertical-align: text-top;
}

button span,
.bulk-actions .selection-tools .close span {
	cursor: pointer;
}

@media only screen and (max-width: 925px) {
	.bulk-actions .tags {
		width: 80%;
	}
	.bulk-actions .selection-tools {
		float: none;
		text-align: right;
		margin-bottom: 20px;
	}
	.bulk-actions.active + * {
		margin-top: 100px;
	}
}

.bookmarks-empty {
	width: 200px;
	margin: 200px auto;
}

.bookmarks {
	display: flex;
	flex-wrap: wrap;
	padding: 0 20px 20px 0;
}

.bookmark-card {
	position: relative;
	box-sizing: border-box; /*necessary for hover effect goodness to work*/
	flex-grow: 1;
	width: 225px;
	height: 225px;
	margin: 20px 0 0 20px;
	padding: 15px;
	background-color: rgb(210, 210, 210);
	background-size: cover;
	background-position: center top;
	box-shadow: inset 0 0 100px rgba(0, 0, 0, 0.65);
	opacity: 0.93;
	border: 2px solid white;
}

.bookmark-card:hover,
.bookmark-card:focus {
	opacity: 1;
	cursor: pointer;
}

.selection-active .bookmark-card {
	opacity: 0.45;
}
.selection-active .bookmark-card:hover,
.selection-active .bookmark-card:focus {
	opacity: 0.6;
	cursor: pointer;
}

.bookmark-card .select-mode-checkbox + label {
	display: none;
	transform: scale(2);
	position: absolute;
	top: 40%;
	left: 45%;
	box-shadow: 0 0 10px white;
	background: white;
	border-radius: 3px;
}
.selection-active .bookmark-card .select-mode-checkbox + label {
	display: block;
}

.bookmark-card.active,
.bookmark-card.active:hover {
	border-color: #0082c9;
	opacity: 1;
}

.bookmark-card .panel {
	position: absolute;
	bottom: 0;
	left: 0;
	right: 0;
	padding: 15px;
	background: rgba(255, 255, 255, 0.8);
	/*
	background: -moz-linear-gradient(
		top,
		rgba(0, 0, 0, 0) 0%,
		rgba(0, 0, 0, 0.4) 37%,
		rgba(0, 0, 0, 0.65) 100%
	);
	background: -webkit-linear-gradient(
		top,
		rgba(0, 0, 0, 0) 0%,
		rgba(0, 0, 0, 0.4) 37%,
		rgba(0, 0, 0, 0.65) 100%
	);
	background: linear-gradient(
		to bottom,
		rgba(0, 0, 0, 0) 0%,
		rgba(0, 0, 0, 0.4) 37%,
		rgba(0, 0, 0, 0.65) 100%
	);*/
}

.bookmark-card .panel:hover {
	background: rgba(255, 255, 255, 0.85);
}

.bookmark-card .popovermenu {
	position: absolute;
	top: 50px;
	right: 5px;
	margin-right: -4px;
}

.bookmark-card .toggle-actions {
	background-color: transparent;
	border: none;
	position: absolute;
	top: 15px;
	right: 5px;
}

.bookmark-card .popovermenu .menu-filter-remove {
	display: none;
}
.bookmark-card .popovermenu .menu-filter-add,
.bookmark-card.active .popovermenu .menu-filter-remove {
	display: block;
}
.bookmark-card.active .popovermenu .menu-filter-add {
	display: none;
}

.bookmark-card h2 {
	font-weight: normal;
	font-size: 16px;
	line-height: 1.2;
	text-shadow: 0 0 4px rgba(255, 255, 255, 0.9);
	margin: 0;
	margin-right: 20px;
	height: 40px; /* max two lines */
	box-sizing: border-box;
	overflow: hidden;
	cursor: pointer;
}

.bookmark-card h2:hover {
	text-shadow: 0 0 10px white;
}

.bookmark-card h2.with-favicon {
	/*background-image: bookmark/{id}/favicon*/
	background-position: 0px 0px;
	background-size: 24px 24px;
	background-repeat: no-repeat;
	padding-left: 42px;
}

.bookmark-card h2 a {
	font-weight: normal;
	font-size: 16px;
	color: black;
	cursor: pointer;
	/* extend link 42px to the left without moving text:
		 (for the favicon)
	*/
	padding-left: 42px;
	margin-left: -42px;
}

.bookmark-card .tags {
	max-height: 100px;
	overflow: hidden;
}

.bookmark-card .tag-nav-item {
	border-radius: 8px;
	background: #ebebeb;
	display: inline-block;
	padding: 0 8px;
	margin: 4px;
}

.bookmark-card .tag-nav-item:hover {
	background: #e0e0e0;
}

@media (max-width: 600px) {
	.bookmark-card {
		width: 150px;
		height: 150px;
		margin: 10px 0 0 10px;
	}
	.bookmark-card .panel {
		padding: 15px 10px;
	}
	.bookmark-card h2.with-favicon {
		/*background-image: bookmark/{id}/favicon*/
		background-position: 0px 3px;
		background-size: 16px 16px;
		background-repeat: no-repeat;
		padding-left: 0;
	}
	.bookmark-card h2 a {
		font-size: 14px;
		padding-left: 20px;
		margin-left: 0;
	}
}
.bookmark-detail {
	position: fixed;
	top: 45px;
	right: 0;
	z-index: 2;
	width: 450px;
	height: 100%;
	box-sizing: border-box;
	padding: 20px;
	background: white;
	color: #333;
	overflow-y: auto;
	box-shadow: 0 0 5px rgba(0, 0, 0, 0.5);
}

.bookmark-detail.slide-in {
	animation: slide-in 0.2s both 1;
}

.bookmark-detail.slide-out {
	animation: slide-out 0.2s both 1;
}

@keyframes slide-in {
	0% {
		right: -450px;
	}
	100% {
		right: 0;
	}
}

@keyframes slide-out {
	0% {
		right: 0;
	}
	100% {
		right: -450px;
	}
}

@media only screen and (max-width: 768px) {
	.bookmark-detail {
		width: auto;
		left: 0;
	}
}

.bookmark-detail .preview {
	height: 240px;
	background-size: cover;
	background-position: center 0;
	box-shadow: inset 0 0 150px rgba(0, 0, 0, 0.65);
	margin: -20px;
	margin-bottom: 20px;
}

.bookmark-detail h1 {
	min-height: 25px;
	font-size: 23px;
	line-height: 1.2;
	cursor: text;
}

.bookmark-detail h1.empty {
	opacity: 0.4;
}

.bookmark-detail h2 {
	margin-top: 12px;
	opacity: 0.4;
}
.bookmark-detail h2 .edit {
	float: right;
}
.bookmark-detail h3 {
	margin-top: 20px;
	margin-bottom: 12px;
	border-bottom: 1px solid #ebebeb;
}

.bookmark-detail h2 :link:hover {
	text-decoration: underline;
}

.bookmark-detail h2 :link span {
	display: inline-block;
	vertical-align: middle;
	margin-right: 3px;
}

.bookmark-detail > .close {
	position: absolute;
	top: 0;
	right: 0;
	width: 40px;
	height: 40px;
	cursor: pointer;
	background-color: rgba(255, 255, 255, 0.3);
}

.bookmark-detail .status {
	position: absolute;
	top: 16px;
	left: 40px;
	font-size: 16px;
	opacity: 0.6;
}
.bookmark-detail .status [class^='icon-'] {
	display: inline-block;
}
.bookmark-detail .status .message {
	display: none;
	background-color: rgba(255, 255, 255, 0.7);
	padding: 4px;
}
.bookmark-detail .status.saving .message.message-saving {
	display: inline;
	position: relative;
	left: 8px;
}
.bookmark-detail .status.saved .message.message-saved {
	display: inline;
	animation: fadeout ease 5s both 1;
}
@keyframes fadeout {
	0% {
		opacity: 1;
		display: inline;
	}
	99% {
		opacity: 0;
		display: inline;
	}
	100% {
		opacity: 0;
		display: none;
	}
}

.bookmark-detail .actions {
	position: absolute;
	right: 40px;
}

.bookmark-detail .actions button {
	height: 40px;
	width: 40px;
}

.bookmark-detail
	.select2-container--default
	.select2-selection--multiple
	.select2-selection__choice,
.bulk-actions
	.select2-container--default
	.select2-selection--multiple
	.select2-selection__choice,
.bookmark-detail .tag-nav-item {
	border-radius: 8px;
	border: none;
	background: #ebebeb;
	display: inline-block;
	padding: 2px 8px;
}

.bookmark-detail
	.select2-container--default
	.select2-selection--multiple
	.select2-selection__choice:hover,
.bulk-actions
	.select2-container--default
	.select2-selection--multiple
	.select2-selection__choice:hover,
.bookmark-detail .tag-nav-item:hover {
	background: #e0e0e0;
}

.bookmark-detail .description {
	margin-top: 20px;
	font-size: 16px;
	/*for editing*/
	width: auto;
	min-height: 300px;
	cursor: text;
}

.bookmark-detail .description.empty {
	opacity: 0.4;
}

.tags-management {
	overflow-y: auto !important;
	height: 80% !important;
	height: calc(100% - 80px - 100px) !important;
}

@media only screen and (max-width: 768px) {
	.tags-management {
		width: auto;
		float: none;
		border-bottom: 2px solid #bbb;
	}
}

.tags-management .tag-man-item {
	cursor: pointer;
}

.tags-management .tag-man-item.active {
	background: #f3f3f3;
}

.tags-management .tag-man-item > a {
	padding-left: 12px !important;
}

.tags-management .tag-man-item .actions {
	float: right;
}

.tags-management .tag-man-item .actions ul {
	display: block !important;
}

.tags-management .tag-man-item .actions .action {
	display: inline-block;
	width: auto !important;
}

.tags-management .tag-man-item .action button {
	border: none;
	background-color: transparent;
	opacity: 0.45;
	padding: 3px 12px;
}

.tags-management .tag-man-item .action button:hover {
	opacity: 1;
}

.tags-management .tag-man-item input[type='text'] {
	min-height: 28px;
	padding: 0 4px;
	margin: 0;
	width: 70%;
}

/* make checkbox look like an icon */
.menu-item span {
	margin: 0;
}

.menu-item-checkbox span:first-child {
	padding: 5px 5px;
	margin: 0;
}

/* display 'remove from filter' when selected, and 'add to ...' when unselected*/

.tags-management .tag-man-item.active .menu-filter-add {
	display: none;
}

.tags-management .tag-man-item .menu-filter-remove {
	display: none;
}

.tags-management .tag-man-item.active .menu-filter-remove {
	display: block;
}

.settings {
	position: absolute;
	bottom: 0;
}

#app-navigation .settings h3 {
	padding-top: 0;
	padding-left: 0;
	border-top: none;
}

.settings .button {
	display: inline-block;
}

.settings .import-form {
	display: inline-block;
}

.settings .import {
	display: none;
}

.settings .upload {
	display: none;
}
