/**
 * Image Widget Plus: Custom Thickbox Styles
 *
 * Copyright (c) 2017 Modern Tribe, Inc.
 */

/* Main image section. */
#TB_window {
	border-radius: 4px;
}

#TB_window img#TB_Image {
	border: 0 none;
	border-top-left-radius: 4px;
	border-top-right-radius: 4px;
	margin: 0;
	width: 100%;
}

/* The "Close" button. */
#TB_closeWindow {
	border: 0 none;
	padding: 0;
	position: absolute;
	right: -9px;
	top: -9px;
	width: 100%;
}

/**
 * Encoding the SVG using the method described here: https://codepen.io/tigt/post/optimizing-svgs-in-data-uris
 **/
#TB_closeWindowButton {
	/* this background image has the fill set to #000 */
	background: url( "data:image/svg+xml;utf8,%3Csvg width='32px' height='32px' viewBox='0 0 64 64' xmlns='http://www.w3.org/2000/svg'%3E%3Cg transform='translate(2 2)' fill='none' fill-rule='evenodd'%3E%3Ccircle stroke='%23fff' fill='%23000' stroke-width='3' cx='30' cy='30' r='30'/%3E%3Cpath fill='%23fff' d='M32.88 30l9.253-9.185c.41-.41.617-.96.617-1.51 0-.546-.275-1.027-.617-1.37-.892-.752-2.193-.752-2.88 0L30 27.122l-9.185-9.253c-.41-.41-.96-.617-1.51-.617-.546 0-1.027.275-1.37.617-.34.41-.547.892-.547 1.44 0 .616.206 1.097.617 1.44L27.12 30l-9.253 9.185c-.41.41-.617.96-.617 1.51 0 .546.275 1.027.617 1.37.41.34.892.547 1.44.547.547 0 1.097-.206 1.44-.617L30 32.88l9.185 9.253c.41.41.892.617 1.44.617h.07c.546 0 1.027-.275 1.37-.617.752-.823.752-2.125.068-2.88L32.88 30z'/%3E%3C/g%3E%3C/svg%3E" );
	background-size: cover;
	height: 32px;
	width: 32px;
}

#TB_closeWindowButton:hover {
	/* this background image has the fill set to #222 */
	background: url( "data:image/svg+xml;utf8,%3Csvg width='32px' height='32px' viewBox='0 0 64 64' xmlns='http://www.w3.org/2000/svg'%3E%3Cg transform='translate(2 2)' fill='none' fill-rule='evenodd'%3E%3Ccircle stroke='%23fff' fill='%23222' stroke-width='3' cx='30' cy='30' r='30'/%3E%3Cpath fill='%23fff' d='M32.88 30l9.253-9.185c.41-.41.617-.96.617-1.51 0-.546-.275-1.027-.617-1.37-.892-.752-2.193-.752-2.88 0L30 27.122l-9.185-9.253c-.41-.41-.96-.617-1.51-.617-.546 0-1.027.275-1.37.617-.34.41-.547.892-.547 1.44 0 .616.206 1.097.617 1.44L27.12 30l-9.253 9.185c-.41.41-.617.96-.617 1.51 0 .546.275 1.027.617 1.37.41.34.892.547 1.44.547.547 0 1.097-.206 1.44-.617L30 32.88l9.185 9.253c.41.41.892.617 1.44.617h.07c.546 0 1.027-.275 1.37-.617.752-.823.752-2.125.068-2.88L32.88 30z'/%3E%3C/g%3E%3C/svg%3E" );
}

#TB_closeWindowButton .tb-close-icon {
	display: none;
}

/* Captions and Prev/Next buttons. */
#TB_caption {
	font-weight: 700;
	height: auto !important;
	text-align: center;
	width: 100%;
}

#TB_caption #TB_secondLine {
	color: #898989;
	font-size: .85em;
	font-weight: 400;
}

/* Hide "Image 1 of 1" text if there's indeed only one image. */
.tribe-image--thickbox-single #TB_secondLine {
	display: none;
}

.tribe-image--thickbox-single.tribe-image--no-caption #TB_caption {
	display: none;
}

.tribe-image--thickbox-single.tribe-image--no-caption #TB_Image {
	border-bottom-left-radius: 4px;
	border-bottom-right-radius: 4px;
}

#TB_next,
#TB_prev {
	position: absolute;
	bottom: 1%;
}

#TB_next {
	float: right;
	right: 7px;
}

#TB_prev {
	float: left;
	left: 7px;
}

#TB_next a,
#TB_prev a {
	display: none;
}

#TB_next::after,
#TB_prev::before {
	background: none;
	color: #898989;
	font-family: 'dashicons';
	font-size: 20px;
	padding: 3px;
}

#TB_next::after {
	content: "\f344"; /* "Right arrow" dashicon */
}

#TB_prev::before {
	content: "\f340"; /* "Left arrow" dashicon */
}

#TB_next:hover::after,
#TB_prev:hover::before {
	background: none;
	color: #2786ba;
	cursor: pointer;
}

#TB_window {
	max-width: calc( 100% - 40px ) !important;
}
