
/* Gallery rework */
#elGalleryHeader {
	margin: -15px -15px 15px -15px;
}
	
	body.ipsLayout_sidebarUsed #elGalleryHeader {
		margin-right: 0;
	}
	html[dir="rtl"] body.ipsLayout_sidebarUsed #elGalleryHeader {
		margin-left: 0;
	}

#elGalleryImage {
	background: #333333;
	min-height: 300px;
	padding: 20px;
	position: relative;
	text-align: center;
}

#elGalleryNav {
	padding: 10px;
	background: #222;
	min-height: 90px;
	text-align: center;
	color: #9f9f9f;
	font-size: 11px;
}
	
	.cGalleryAlbumSlider_wrapper {
		width: 350px;
		overflow: hidden;
		position: relative;
		height: 50px;
	}

	.cGalleryAlbumSlider {
		display: inline-block;
		white-space: nowrap;
		font-size: 0px !important;
		position: absolute;
		top: 0;
	}
	html[dir="ltr"] .cGalleryAlbumSlider {
		left: 0;
	}
	html[dir="rtl"] .cGalleryAlbumSlider {
		right: 0;
	}

		.cGalleryAlbumSlider .cGalleryTrimmedImage {
			background-color: #222;
		}

		.cGalleryAlbumSlider li {
			display: inline-block;
			width: 50px;
			height: 50px;
			overflow: hidden;
		}
			
			.cGalleryAlbumSlider li {
				border: 2px solid #222;
				background-size: cover;
				background-position: 50% 50%;
			}

				.cGalleryAlbumSlider li.cGalleryAlbumSlider_active {
					border-color: #5490c0;
				}

			.cGalleryAlbumSlider li a {
				display: block;
				height: 100%;
			}

			html[dir="ltr"] .cGalleryAlbumSlider li:last-child {
				margin-right: 0;
			}
			html[dir="rtl"] .cGalleryAlbumSlider li:last-child {
				margin-left: 0;
			}

			#elGalleryNav > ul > li {
				margin: 0;
			}

			#elGalleryNav a[data-action] {
				width: 17px;
				text-align: center;
				line-height: 50px;
				font-size: 28px;
				color: #fff;
				-webkit-transition: 0.1s all linear;
	-moz-transition: 0.1s all linear;
	-ms-transition: 0.1s all linear;
	-o-transition: 0.1s all linear;
	transition: 0.1s all linear;
			}

				#elGalleryNav a[data-action][data-disabled] {
					cursor: default;
					opacity: 0.2;
				}

		.cGalleryAlbumSlider .ipsAreaBackground {
			background: rgba(0,0,0,0.2);
		}

.cGalleryMiniAlbum li {
	position: relative;
}

	.cGalleryMiniAlbum li a {
		position: absolute;
		top: 0;
		left: 0;
		bottom: 0;
		right: 0;
	}

#elGalleryImageStats [data-ipsRating] > .ipsRating {
	float: none;
}

#elGalleryImageNav a {
	position: absolute;
	color: #fff;
	font-size: 60px;
	top: 50%;
	margin-top: -30px;
	padding: 0 15px;
}

	html[dir="ltr"] #elGalleryImageNav_prev {
		left: 0px;
	}
	html[dir="rtl"] #elGalleryImageNav_prev {
		right: 0px;
	}

	html[dir="ltr"] #elGalleryImageNav_next {
		right: 0px;
	}
	html[dir="rtl"] #elGalleryImageNav_next {
		left: 0px;
	}

/* PATCHWORK */
.cGalleryPatchwork_item {
	display: block;
	float: left;
	background-size: cover;
	background-color: #333;
	position: relative;
	overflow: hidden;
	text-shadow: 1px 1px 0px rgba(0,0,0,0.8);
	text-align: left;
}
html[dir="rtl"] .cGalleryPatchwork_item {
	float: right;
	text-align: right;
}
	
	.cGalleryPatchwork_item > a {
		position: absolute;
		display: block;
		top: 0;
		left: 0;
		right: 0;
		bottom: 0;
	}

	.cGalleryPatchwork_item [data-role='moderation'] {
		position: absolute;
		top: 5px;
	}
	html[dir="ltr"] .cGalleryPatchwork_item [data-role='moderation'] {
		right: 5px;
	}
	html[dir="rtl"] .cGalleryPatchwork_item [data-role='moderation'] {
		left: 5px;
	}

	.cGalleryPatchwork_item [data-commentCount='0'] {
		opacity: 0.3;
	}

	.cGalleryPatchwork_item.ipsNoThumb {
		text-shadow: none;
	}

.cGalleryPatchwork_image {
	position: absolute;
	top: 0;
	width: 100%;
	height: 100%;
}
html[dir="ltr"] .cGalleryPatchwork_image {
	left: 0;
}
html[dir="ltr"] .cGalleryPatchwork_image {
	right: 0;
}

.cGalleryPatchwork_item .ipsPhotoPanel {
	position: absolute;
	background: rgba(0,0,0,0.8);
	width: 100%;
	top: 0;
	line-height: 1.2;
	height: 42px;
	color: #fff;
	opacity: 0;
	-webkit-transition: opacity 0.1s linear;
	-moz-transition: opacity 0.1s linear;
	-ms-transition: opacity 0.1s linear;
	-o-transition: opacity 0.1s linear;
	transition: opacity 0.1s linear;
}
html[dir="ltr"] .cGalleryPatchwork_item .ipsPhotoPanel {
	left: 0;
	padding: 7px 0 0 7px;
}
html[dir="rtl"] .cGalleryPatchwork_item .ipsPhotoPanel {
	right: 0;
	padding: 7px 7px 0 0;
}

	.cGalleryPatchwork_item .ipsPhotoPanel span {
		line-height: inherit;
		display: block;
		width: 100%;
		white-space: nowrap;
		text-overflow: ellipsis;
	}

	.cGalleryPatchwork_item .ipsPhotoPanel span + span {
		opacity: 0.7;
	}

	.cGalleryPatchwork_item:hover .ipsPhotoPanel {
		opacity: 1;
	}

/* Image list patchwork */
.cGalleryPatchwork_list .cGalleryPatchwork_stats {
	position: absolute;
	bottom: 0;
	left: 0;
	right: 0;
	font-size: 13px;
	color: #fff;
	padding: 7px;
	background: -moz-linear-gradient(top, rgba(0,0,0,0) 0%, rgba(0,0,0,0.6) 100%);
	background: -webkit-gradient(linear, left top, left bottom, color-stop(0%,rgba(0,0,0,0)), color-stop(100%,rgba(0,0,0,0.6)));
	background: -webkit-linear-gradient(top, rgba(0,0,0,0) 0%,rgba(0,0,0,0.6) 100%);
	background: -o-linear-gradient(top, rgba(0,0,0,0) 0%,rgba(0,0,0,0.6) 100%);
	background: -ms-linear-gradient(top, rgba(0,0,0,0) 0%,rgba(0,0,0,0.6) 100%);
	background: linear-gradient(to bottom, rgba(0,0,0,0) 0%,rgba(0,0,0,0.6) 100%);
}

/* Featured/New patchwork */
.cGalleryPatchwork_index {
	padding-top: 3px;
	padding-bottom: 3px;
}

.cGalleryPatchwork_index .cGalleryPatchwork_item .cGalleryPatchwork_comments {
	position: absolute;
	bottom: 7px;
	color: #fff;
	font-size: 12px;
}
html[dir="ltr"] .cGalleryPatchwork_index .cGalleryPatchwork_item .cGalleryPatchwork_comments {
	right: 7px;
}
html[dir="rtl"] .cGalleryPatchwork_index .cGalleryPatchwork_item .cGalleryPatchwork_comments {
	left: 7px;
}

/* CATEGORIES */
.cGalleryCats {
	padding: 7px;
}
	
	.cGalleryCats > .ipsGrid {
		margin-bottom: -15px;
	}

.cGalleryCat > a {
	display: block;
	height: 150px;
	position: relative;
	color: #fff;
}
	
	.cGalleryCat > a:before {
		content: '';
		display: block;
		position: absolute;
		bottom: 0;
		left: 0;
		right: 0;
		height: 53px;
		background: rgba(0,0,0,0.8);
	}
	
	.cGalleryCat .ipsType_sectionHead,
	.cGalleryCat .cGalleryCat_info {
		position: absolute;
		left: 7px;
		right: 7px;
		text-shadow: 1px 1px 1px rgba(0,0,0,1);
	}

	.cGalleryCat .ipsType_sectionHead {
		bottom: 23px;
		color: #fff;
		font-size: 15px;
	}

	.cGalleryCat .cGalleryCat_info {
		bottom: 7px;
		font-size: 11px;
	}

/* ALBUM LIST IN A CATEGORY */
.cGalleryAlbums > li:not( :last-child ) {
	margin-bottom: 7px;
}

.cGalleryAlbums_recent > ul {
	height: 204px;
	position: relative;
	overflow: hidden;
}
html[dir="ltr"] .cGalleryAlbums_recent > ul {
	padding-left: 208px;
}
html[dir="rtl"] .cGalleryAlbums_recent > ul {
	padding-right: 208px;
}

.cGalleryAlbums_recent > ul > li {
	width: 100px;
	height: 100px;
	float: left;
	position: relative;
	margin: 0 0 4px 4px;
}
html[dir="rtl"] .cGalleryAlbums_recent > ul > li {
	float: right;
	margin: 0 4px 4px 0;
}
	
	.cGalleryAlbums_recent > ul > li a {
		display: block;
		width: 100px;
		height: 100px;
	}

	.cGalleryAlbums_recent > ul > li span {
		padding-right: 7px;
		text-align: right;
		font-size: 11px;
		font-weight: bold;
		color: #fff;
		position: absolute;
		left: 0;
		right: 0;
		bottom: 0;
		line-height: 26px;
		text-shadow: 1px 1px 0px rgba(0,0,0,0.8);
		background-image: -moz-linear-gradient(top, rgba(0,0,0,0) 0%, rgba(0,0,0,0.6) 100%);
		background-image: -webkit-gradient(linear, left top, left bottom, color-stop(0%,rgba(0,0,0,0)), color-stop(100%,rgba(0,0,0,0.6)));
		background-image: -webkit-linear-gradient(top, rgba(0,0,0,0) 0%,rgba(0,0,0,0.6) 100%);
		background-image: -o-linear-gradient(top, rgba(0,0,0,0) 0%,rgba(0,0,0,0.6) 100%);
		background-image: -ms-linear-gradient(top, rgba(0,0,0,0) 0%,rgba(0,0,0,0.6) 100%);
		background-image: linear-gradient(to bottom, rgba(0,0,0,0) 0%,rgba(0,0,0,0.6) 100%);
	}
	html[dir="rtl"] .cGalleryAlbums_recent > ul > li span {
		text-align: left;
	}

	.cGalleryAlbums_recent > ul > li img {
		display: none;
	}

	.cGalleryAlbums_recent > ul > li:first-child {
		width: 204px;
		height: 204px;
		overflow: hidden;
		position: absolute;
	}
	html[dir="ltr"] .cGalleryAlbums_recent > ul > li:first-child {
		left: 0;
	}
	html[dir="rtl"] .cGalleryAlbums_recent > ul > li:first-child {
		right: 0;
	}

		.cGalleryAlbums_recent > ul > li:first-child a {
			width: 204px;
			height: 204px;
		}

html[dir="ltr"] .cGalleryEvents .ipsDataList .ipsDataItem,
html[dir="ltr"] .cGalleryEvents .ipsDataList .ipsDataItem_icon {
	padding-left: 0 !important;
}
html[dir="rtl"] .cGalleryEvents .ipsDataList .ipsDataItem,
html[dir="rtl"] .cGalleryEvents .ipsDataList .ipsDataItem_icon {
	padding-right: 0 !important;
}

.cGalleryImageList > li {
	padding: 7px;
	border: 1px solid rgba(0,0,0,0.05);
}

	.cGalleryImageList > li > div {
		width: 100%;
		margin-bottom: 5px;
	}

		/* For non-js, we need a fixed height because the JS won't be handling it */
		.ipsJS_none .cGalleryImageList > li > div {
			height: 180px;
		}

		.cGalleryImageList > li > div + ul {
			height: 26px;
			line-height: 24px;
		}

.cGalleryImageItem.cGalleryImageItem_selected {
	background-color: #ebf4f9;
}

.cGalleryImageItem_image {
	display: block;
	position: relative;
	max-width: 100%;
	height: 100%;
}

.cGalleryLargeList > li {
	margin-bottom: 15px;
	border: 1px solid rgba(0,0,0,0.05);
}

	.cGalleryLargeList > li img {
		display: block;
		margin: 0 auto 10px auto;
	}

/* IMAGE VIEW PAGE */
.cGalleryViewImage {
	/* Needed for FF & IE */
	display: inline-block;
	/*table-layout: fixed;
	width: 100%;
	min-height: 100%;*/
	/* -- */
	position: relative;
	margin-bottom: 5px;
}
	
	.cGalleryViewImage_controls {
		position: absolute;
		top: 15px;
		opacity: 0;
		-webkit-transition: 0.3s all linear;
	-moz-transition: 0.3s all linear;
	-ms-transition: 0.3s all linear;
	-o-transition: 0.3s all linear;
	transition: 0.3s all linear;
	}
	html[dir="ltr"] .cGalleryViewImage_controls {
		right: 15px;
	}
	html[dir="rtl"] .cGalleryViewImage_controls {
		left: 15px;
	}

		#elGalleryImage:hover .cGalleryViewImage_controls {
			opacity: 1;
		}

.cGalleryViewImage_options {
	margin-bottom: 5px;
}
	
.cGalleryExif .fa-camera {
	font-size: 42px;
	line-height: 58px;
}

.cGalleryExif_data {
	margin: 5px 0;
}

	.cGalleryExif_data li {
		border: 2px solid #5d5d5d;
		border-radius: 5px;
		line-height: 20px;
		height: 24px;
		font-size: 12px;
		font-weight: bold;
		margin: 4px 2px;
	}
	html[dir="ltr"] .cGalleryExif_data li {
		padding-right: 6px;
	}
	html[dir="rtl"] .cGalleryExif_data li {
		padding-left: 6px;
	}

		.cGalleryExif_data li span {
			background: #5d5d5d;
			color: #fff;
			width: 30px;
			font-size: 15px;
			display: inline-block;
			text-align: center;
		}
		html[dir="ltr"] .cGalleryExif_data li span {
			float: left;
			padding: 0 8px 0 6px;
			margin-right: 6px;
		}
		html[dir="rtl"] .cGalleryExif_data li span {
			float: right;
			padding: 0 6px 0 8px;
			margin-left: 6px;
		}

	.cGalleryExif .cGalleryExif_f {
		font-family: 'Palatino', 'Times New Roman';
		font-style: italic;
		font-weight: bold;
	}

	.cGalleryExif .cGalleryExif_iso {
		font-size: 11px;
		padding: 0;
	}

/* IMAGE SIZES */
#elGalleryImage_sized {
	margin: 15px 0;
	background: #333333;
	padding: 15px;
	text-align: center;
}

/* NOTES */
.cGalleryViewImage_addNote {
	cursor: crosshair;
}

.cGalleryViewImage:hover .cGalleryNote {
	opacity: 1;
}

.cGalleryNote {
	position: absolute;
	opacity: 0;
}

.cGalleryNote_border {
	border: 1px solid #000;
	height: 100%;
	background: rgba(255,255,255,0.0001);
}

	.cGalleryNote_border:after {
		position: absolute;
		left: 1px;
		right: 1px;
		top: 1px;
		bottom: 1px;
		content: '';
		display: block;
		border: 1px solid #ccc;
	}

	.cGalleryNote_editing .cGalleryNote_border,
	.cGalleryNote_editing .cGalleryNote_border:after {
		border-style: dashed;
		opacity: 1;
	}

.cGalleryNote_editing {
	opacity: 1 !important;
}

	.cGalleryNote_editing .cGalleryNote_note {
		opacity: 1 !important;
		display: block !important;
		max-width: 220px;
		width: 220px;
		padding: 4px;
		pointer-events: auto;
	}

		.cGalleryNote_editing .cGalleryNote_note ul {
			text-align: left;
			margin-top: 5px;
		}
		html[dir="rtl"] .cGalleryNote_editing .cGalleryNote_note ul {
			text-align: right;
		}

		.cGalleryNote_editing .cGalleryNote_note a {
			color: #fff;
		}

		.cGalleryNote_editing .cGalleryNote_note textarea {
			font-size: 11px;
			color: #000;
		}

.cGalleryNote_note {
	max-width: 200px;
	padding: 4px 10px;
	position: absolute;
	top: 100%;
	margin-top: 5px;
	background: #2a2a2a;
	color: #fff;
	font-size: 12px;
	border-radius: 2px;
	pointer-events: none;
}
html[dir="ltr"] .cGalleryNote_note {
	left: 0px;
}
html[dir="rtl"] .cGalleryNote_note {
	right: 0px;
}

.cGalleryNote_delete { 
	position: absolute;
	top: -10px;
	width: 24px;
	height: 24px;
	line-height: 19px;
	border-radius: 12px;
	background: #000;
	border: 1px solid #fff;
	color: #fff;
	font-size: 17px;
}
html[dir="ltr"] .cGalleryNote_delete {
	right: -10px;
}
html[dir="rtl"] .cGalleryNote_delete {
	left: -10px;
}

/* jQuery resizable styles */
.ui-resizable-handle { position: absolute; font-size: 0.1px; display: block; }
.ui-resizable-disabled .ui-resizable-handle, .ui-resizable-autohide .ui-resizable-handle { display: none; }
.ui-resizable-n { cursor: n-resize;	height: 7px; width: 100%; top: -5px; left: 0; }
.ui-resizable-s { cursor: s-resize;	height: 7px; width: 100%; bottom: -5px;	left: 0; }
.ui-resizable-e { cursor: e-resize; width: 7px;	right: -5px; top: 0; height: 100%; }
.ui-resizable-w { cursor: w-resize;	width: 7px;	left: -5px;	top: 0;	height: 100%; }
.ui-resizable-se { cursor: se-resize; width: 12px; height: 12px; right: 1px; bottom: 1px; }
.ui-resizable-sw { cursor: sw-resize; width: 9px; height: 9px; left: -5px; bottom: -5px; }
.ui-resizable-nw { cursor: nw-resize; width: 9px; height: 9px; left: -5px; top: -5px; }
.ui-resizable-ne { cursor: ne-resize; width: 9px; height: 9px; right: -5px;	top: -5px; }
.ui-icon-gripsmall-diagonal-se {
	background: url( http://siamtovar.us/forum/themes/1/resources/core/global/resizable.png );
}
.ui-draggable { cursor: move;}

/* General style which creates the square thumb container */
.cGalleryTrimmedImage {
	background-color: #333;
	background-size: cover;
	background-position: 50%;
	background-repeat: no-repeat;
	overflow: hidden;
}

	.cGalleryTrimmedImage img {
		display: none;
	}

.cGalleryThumb {
	max-width: 170px;
	max-height: 170px;
}

/* This is to make the video responsive in size
	See: http://3strandsmarketing.com/video-fluid-2.php */
.cGallery_videoContainer {
	position: relative;
	height: 100%;
}

	.cGallery_videoContainer .video-js {
		position: absolute;
		top: 0;
		width: 100%;
		height: 100%;
	}
	html[dir="ltr"] .cGallery_videoContainer .video-js {
		left: 0;
	}
	html[dir="rtl"] .cGallery_videoContainer .video-js {
		right: 0;
	}