#files .entry,
#temp .row-fluid {
	touch-action: pan-y;
}

#files_wrapper {
	position: relative;

	.accordion-heading {
		display: block;
		pointer-events: none;
		margin: 40px -@main-gutter 0;
		padding: 0.5rem @main-gutter;

		background-color: @main-color;
		color: @main-color-text;

		> a, > a i {
			color: @main-color-text;
			.rem(font-size, 23);
			padding-right: 0;
			padding-left: 0;
		}
		> div {
			pointer-events: all;
			margin: -8px 5px -8px 0;

			&.settings-trigger {
				position: relative;
				margin-right: -10px;
			}

			> a {
				background: transparent;
				padding: 15px 10px !important;
				margin: 0;

				//@media (max-width: 350px) {
				//	padding: 9px 4px;
				//}

				* {
					display: none;
				}

				&:after {
					.font-icon-reset();
					content: @fa-legacy-var-filter;
					.rem(font-size, 25);
					color: @main-color-text;
				}
			}
		}

		.icon-wrench,
		.icon-refresh,
		.icon-sd-black-14 {
			display: none !important;
		}

		.sd-trigger {
			.dropdown-toggle {
				&:after {
					content: @fa-legacy-var-paste;
					top: 3px;
					position: relative;
				}
			}
		}

		.refresh-trigger {
			a {
				&:after {
					content: @fa-legacy-var-refresh;
				}
			}
		}

		.upload-trigger {
			a {
				&:after {
					content: @fa-legacy-var-upload;
				}
			}
		}
	}

	#files {
		#gcode_upload_progress + div .muted {
			display: none;
		}

		.form-search {
			display: none;
		}

		// Deprecated 1.3.9
		.slimScrollDiv {
			margin: 0 -@main-gutter 10px;
			height: auto !important;
			clear: both;
		}

		// Introduced 1.3.9
		.scroll-wrapper {
			margin: 0 -@main-gutter 10px;
			height: auto !important;
			overflow: hidden;
			clear: both;
		}

		.text-right.muted {
			text-align: center;
		}

		.upload-buttons,
		.folder-button {
			.btn {
				padding: 12px;
				.rem(font-size, 22);
				display: block;
				width: 100%;
				margin-left: 0;

				&:last-child {
					border-left: 1px solid @main-background;
				}

				@media (min-width: 510px) {
					width: 50%;
					display:inline-block;
					.border-radius(0, 5px, 5px, 0);

					&:first-child {
						.border-radius(5px, 0, 0, 5px);
					}
				}
			}
		}
		.folder-button {
			margin-top: 10px;

			.btn {
				border: 0 none;
				width: 100%;
			}
		}

		.gcode_files {
			height: auto !important;
			margin: 0 -0 10px;
			padding: 0;

			.entry {
				background-color: @swipe-list-background-color;
				color: contrast(@swipe-list-background-color);
				border-top: 1px solid @main-background;

				.rem(font-size, 14);
				.rem(line-height, 20);

				padding: 15px (@main-gutter + 110px) 15px @main-gutter;
				margin: 0;
				position: relative;
				left: 0;
				clear: both;
				cursor: w-resize;

				transition: left 0.4s ease, background 0.7s ease, color 0.7s ease;

				.title.text-success:after {
					.font-icon-reset();
					content: @fa-legacy-var-check;
					padding-left: 10px;
				}

				&.open {
					left: -(@main-gutter + 90px);
					background: @swipe-list-background-open-color;
					color: contrast(@swipe-list-background-open-color);

					&.large {
						left: -(@main-gutter + 200px);
					}

					&:hover,
					&:after {
						background: @swipe-list-background-open-color;
						color: contrast(@swipe-list-background-open-color);
					}
					div.action-buttons {
						.btn {
							color: contrast(@swipe-list-background-open-color);
						}
					}
					div:not(.title) {
						color: fade(contrast(@swipe-list-background-open-color), 70%);
					}
				}

				&:after {
					transition: left 0.4s ease, background 0.7s ease;

					content: "";
					display: block;
					top: 0;
					height: 100%;
					width: (@main-gutter + 240px);
					right: -(@main-gutter + 240px);
					position: absolute;
					transition: background 0.7s ease;

					background: @swipe-list-background-color;
					color: contrast(@swipe-list-background-color);
				}

				div,
				div span {
					color: inherit;
				}

				div:not(.title) {
					transition: color 0.7s ease;
					color: fade(contrast(@swipe-list-background-color), 70%);
				}

				&.back {
					margin: 0 -@main-gutter;
				}

				&.back, &.folder {
					cursor: default;

					&.clickable {
						cursor: pointer;
					}

					.title {
						color: contrast(@swipe-list-background-color);
					}

					.btn {
						top: 10px !important;
					}
				}

				.additionalInfo {
					padding: 0;
				}

				.btn {
					position: absolute;
					left: 100%;
					top: 21px;
					.border-radius(0);
					background: transparent !important;
					z-index: 5;
					border: 0 none;
					.box-shadow(0 0 0 transparent);
					.text-shadow(0 0 0 transparent);

					color: contrast(@swipe-list-background-color) !important;
					transition: left 0.4s ease, background 0.7s ease, color 0.7s ease;

					&.toggleAdditionalData {
						right: 70px;
						left: auto;
						font-size: 37px;
					}
				}

				div.action-buttons {
					position: static;
					right: auto;
					bottom: auto;
					display: inline;

					i {
						font-size: 32px;
						.rem(line-height, 40);
					}

					.btn.disabled, .btn[disabled] {
						.opacity(0.2);
					}
				}

				&.machinecode {
					.btn {
						&[data-bind*="PRINT"] {
							right: (@main-gutter - 15px);
							left: auto;
						}

						&[data-bind*="FILES_DOWNLOAD"] {
							margin-left: 53px !important;
						}

						&[data-bind*="FILES_DELETE"] {
							margin-left: 110px !important;
						}

						&[data-bind*="FILES_UPLOAD"] {
							margin-left: 160px !important;
						}

						&[data-bind*="FILES_SELECT"] {
							margin-left: 0;
						}
					}
				}

				&.model {
					.btn {
						&[data-bind*="SLICE"] {
							right: (@main-gutter - 15px);
							left: auto;
						}

						&[data-bind*="FILES_DOWNLOAD"] {
							right: (@main-gutter + 40px);
							left: auto;
						}

						&[data-bind*="FILES_UPLOAD"] {
							margin-left: 50px !important;
						}

						&[data-bind*="FILES_DELETE"] {
							margin-left: 0;
						}
					}
				}

				&.folder {
					.btn {
						&[data-bind*="FILES_DELETE"] {
							margin-left: 0;
						}

						&[data-bind*="FILES_UPLOAD"] {
							margin-left: 50px !important;
						}
					}
				}
			}
		}
	}
}
