/*-------------------------------------------------------*/
/* Map viewer chrome */

#mapViewer #NLSLogo, #mapViewerFindByPlace #NLSLogo, #mapViewerGeoRefMaps #NLSLogo, #mapViewerPrint #NLSLogo, #mapViewerSideBySide #NLSLogo {
	width: 131px;
}

#mapViewer #header #pageTitle, #mapViewerSideBySide #header #pageTitle {
	margin-left: 151px;
	max-height: 55px;
	overflow:hidden;
}

#mapViewer #header #attribution  {
	position: absolute;
    	right: 0;
    	bottom: 0;
    	margin: 0px 16px 10px 0;
	font-size: 0.9em;
    	padding: 0;
}

#mapViewerPrint #header #pageTitle {
	margin-left: 151px;
	max-height: 105px;
	overflow:hidden;
}

#mapViewerFindByPlace #header #pageTitle {
	margin-left: 251px;
	max-height: 70px;
	overflow:hidden;
}

#mapViewerFindByPlace .ol-rotate{top:125px;right:220px;}

#mapViewerGeoRefMaps .ol-rotate {top:110px;right:10px;}

#mapViewerGeoRefMaps .ol-zoom {top:110px;left:.5em}
#mapViewerGeoRefMaps .ol-zoomslider {top:200px;left:.5em}
#mapViewerGeoRefMaps .ol-scale-line {bottom:24px;left:8px;}

#mapViewerPrint .ol-zoom{top:95px;left:.5em;}
#mapViewerPrint .ol-rotate {top:95px;right:.5em;}

#mapViewerSideBySide .ol-zoom {top:145px;left:.5em;}
#mapViewerSideBySide .ol-zoomslider {top:215px;left:.5em;}
#mapViewerSideBySide .ol-rotate {top:145px;right:.5em;}


#mapViewerGeoRefMaps #header #pageTitle {
	margin-left: 251px;
	max-height: 70px;
	overflow:hidden;
}

#mapViewer, #mapViewerPrint, #mapViewerFindByPlace, #mapViewerGeoRefMaps {
	background-color: #d9dde6;
}

#mapViewer #header, #mapViewerFindByPlace #header, #mapViewerGeoRefMaps #header, #mapViewerSideBySide #header {
	z-index: 1000;
	max-height: 100px;
}

#mapViewerPrint #header {
	max-height: 80px;
	overflow:hidden;
}

#mapViewer #siteTitle, #mapViewerPrint #siteTitle, #mapViewerFindByPlace #siteTitle, #mapViewerGeoRefMaps #siteTitle, #mapViewerSideBySide #siteTitle {
	float: left;
	margin: 0;
	color: #3A7DC1;
	font-size: 1.1em;
	border: none;
	padding: 18px 0 0 18px;
	margin: 0;
	width: 82px;
}

#mapViewer #mainContentOuter, #mapViewerPrint #mainContentOuter, #mapViewerFindByPlace #mainContentOuter, #mapViewerGeoRefMaps #mainContentOuter, #mapViewerSideBySide #mainContentOuter {
	position: relative;
	background-color: white;
	border-bottom: 1px solid #ccc;
}

#mapViewer #mainContent, #mapViewerPrint #mainContent, #mapViewerFindByPlace #mainContent, #mapViewerGeoRefMaps #mainContent, #mapViewerSideBySide #mainContent {
	position: relative;
	background-color: white;
	max-width: 100%;
	min-height: 500px;
	margin: 0;
	padding: 0;
}

#mapViewer #footer, #mapViewerFindByPlace #footer, #mapViewerGeoRefMaps #footer {
	position: absolute;
	bottom: 0 !important;
	left: 0;
	width: 100%;
	// height: 37px;
	// max-height: 37px;
	background-color: #d9dde6;
	font-size: 0.8em;
	font-weight: bolder;
	margin: 0;
	padding: 0;
	border-top: 1px solid #ccc;
	// overflow: hidden;
	z-index: 100;
}

#mapViewer #footerMenu, 
#mapViewerFindByPlace #footerMenu, 
#mapViewerGeoRefMaps #footerMenu,
#mapViewer #footerMenuSite, 
#mapViewerFindByPlace #footerMenuSite, 
#mapViewerGeoRefMaps #footerMenuSite,
#mapViewer #footerMenuViewer, 
#mapViewerFindByPlace #footerMenuViewer, 
#mapViewerGeoRefMaps #footerMenuViewer {
	margin: 0 0 5px 0;
}

#mapViewer #footerMenu, 
#mapViewerFindByPlace #footerMenu, 
#mapViewerGeoRefMaps #footerMenu,
#mapViewer #footerMenuSite, 
#mapViewerFindByPlace #footerMenuSite, 
#mapViewerGeoRefMaps #footerMenuSite {
	padding: 0 14px 0 0;
}

#mapViewer #footerMenuViewer, 
#mapViewerFindByPlace #footerMenuViewer, 
#mapViewerGeoRefMaps #footerMenuViewer {
	padding: 0 0 0 14px;
}

#mapViewer #tip, #mapViewerFindByPlace #tip, #mapViewerGeoRefMaps #tip, #mapViewer #help, #mapViewerFindByPlace #help, #mapViewerGeoRefMaps #help 
 {
	float: left;
	margin: 0 0 10px 14px;
	padding: 6px 14px;
	background-color: #eee;
	border-right: 1px solid #ccc;
	border-bottom: 1px solid #ccc;
	border-left: 1px solid #ccc;
	line-height: 1em;
}

#mapViewerGeoRefMaps #layers, #mapViewerFindByPlace #layers
 {
	float: left;
	margin: 0 0 14px 0;
	padding: 6px 14px;
	background-color: #eee;
	border-right: 1px solid #ccc;
	border-bottom: 1px solid #ccc;
	border-left: 1px solid #ccc;
	line-height: 1.2em;
}

#mapViewer #help:hover, #mapViewerFindByPlace #help:hover, #mapViewerGeoRefMaps #help:hover, #mapViewerGeoRefMaps a.olControlCustomPermalinkToggle:hover {
	background-color: #666;
	background-image: url(https://maps.nls.uk/assets/graphics/right_bottom_corner_hover.png);
}
#mapViewer #help a, #mapViewerFindByPlace #help a, #mapViewerGeoRefMaps #help, #mapViewerGeoRefMaps a.olControlCustomPermalinkToggle {
	display: block;
	margin: 0;
	padding: 2px 14px 4px 14px;
	background-image: url(https://maps.nls.uk/assets/graphics/left_bottom_corner.png);
	background-position: bottom left;
	background-repeat: no-repeat;
	color: white;
	text-decoration: none;
}
#mapViewer #help a:hover, #mapViewerFindByPlace #help a:hover, #mapViewerGeoRefMaps #help a:hover, #mapViewerGeoRefMaps a.olControlCustomPermalinkToggle:hover {
	background-image: url(https://maps.nls.uk/assets/graphics/left_bottom_corner_hover.png);
}

#mapViewer #footer p, #mapViewerFindByPlace #footer p, #mapViewerGeoRefMaps #footer p {
	margin-bottom: 0;
}

#mapViewer #map, #mapViewerPrint #map, #mapViewerFindByPlace #map, #mapViewerGeoRefMaps #map, #mapViewerSideBySide #mapleft, #mapViewerSideBySide #mapright {
	z-index: 6;
	background-color: white;
	position: absolute;
	height: auto;
	width: auto;
}

#mapViewer #map {
	top: 116px;
	bottom: 37px;
	z-index:1;
}

#mapViewerFindByPlace #map  {
	top: 0px;
	bottom: 37px;
}

#mapViewerGeoRefMaps #map  {
	top: 0px;
	bottom: 52px;
}


#mapViewerPrint #map {
	top: 0px;
	right: 0;
	bottom: 0;
	left: 0;
}

#mapViewerPrint .ol-mouse-position, #mapViewerPrint .ol-zoomslider, #mapViewerPrint .ol-scale-line {
	visibility: hidden;
 }

#mapViewer #map {
	background-image: url(https://maps.nls.uk/assets/graphics/check.png);
}

#mapViewerFindByPlace #map, #mapViewerGeoRefMaps #map {
	left: 0px;
}

#mapViewerFindByPlace #map {
	right: 0px;
}

#mapViewerGeoRefMaps #map {
	right: 0;
}

#mapViewer #map {
	left: 0;
	right: 0;
}


#mapViewer #searchSideBar, #mapViewerFindByPlace #searchSideBar, #mapViewerGeoRefMaps #searchSideBar {
	position: absolute;
	top: 125px;
	// bottom: 41px;
	left: 45px;
	max-width: 250px;
	max-height: 600px;
	z-index: 2000;
	background-color: white;
	overflow:hidden;
	// overflow: auto;
	margin: 0;
	padding: 0px 10px 5px 10px;
	border-radius: 3px;
	// height: 400px;
	background:rgba(255,255,255,0.9);
}

#mapViewerSideBySide #searchSideBar {
	max-height: 40px;
}

#mapViewer #resultsSideBar, #mapViewerFindByPlace #resultsSideBar {
	position: absolute;
	top: 125px;
	// bottom: 41px;
	border-radius: 3px;
	right: 5px;
	width: 180px;
	z-index: 3000;
	background-color: white;
	overflow: auto;
	margin: 0px;
	padding: 10px;
	max-height: 500px;
	background:rgba(255,255,255,0.95);
}

#mapViewerGeoRefMaps #resultsSideBar {
	position: absolute;
	top: 145px;
	// bottom: 41px;
	border-radius: 3px;
	right: 5px;
	width: 180px;
	z-index: 3000;
	background-color: white;
	overflow: auto;
	margin: 0px;
	padding: 10px;
	max-height: 500px;
	background:rgba(255,255,255,0.95);
}



#mapViewerGeoRefMaps #wfsResults {
    position: absolute;
    right: 165px;
    bottom: 9px;
    z-index: 1000000;
    background-color: #FFF;
    border-radius: 2px;
    font-size: 0.75em;
    font-weight: bold;
    opacity: 0.6;
    white-space: nowrap;
}
 

#measurementControlForm {
	position: absolute;
	right: 50px;
	top: 125px;
	z-index:100000;
}



#measurementControlOutput {
	display: none;
	position: absolute;
	right: 5px;
	top: 158px;
	background-color: white;
	z-index:100000;
	font-size: 0.75em;
	font-weight: bold;
	padding: 0 6px;
	border: 1px inset #ddd;
	text-align: right;
	opacity:0.6;
	filter:alpha(opacity=60);
}
#measurementControlOutputReturnLink, #measurementControlOutputSpan {
	display: block;
}
#measurementControlOutputSpan {
	height: 1.7em;
}

#controlToggle {
	visibility: hidden;
}

#show	{
	visibility: visible;
	position: absolute;
	top: 125px;
	left: 45px;
	z-index: 1000;
	font-size: 0.8em;
	text-decoration: underline;
	color: blue;
	background-color: white;
	padding: 5px 5px 5px 5px;
	border-radius: 6px;
}

#show:hover {
	background-color: #D8D8D8;
}

/*-------------------------------------------------------*/
/* Modifications for print page */
#mapViewerPrint #header #pageTitle {
	margin: 0 0 0 270px;
	padding: 16px;
	color: #003;
	font-size: 0.7em;
	border: none;
	line-height: 1.2em;
}

#mapViewerPrint form  {
	display: none;
}


#mapViewerSideBySide #layerSelect {
	display:none;
}



/*-------------------------------------------------------*/
/* Open layers chrome */

/* Mobile Devices - hide header and footer for phones
@media only screen and (max-device-width: 480px), only screen and (-webkit-min-device-pixel-ratio: 2) {
#overview { display:none; }
#header { display:none; }
#footer { display:none; }
.olControlZoom { top: 10px !important; }
} */

/* CSS full-screen layout */
#layerSelect {position: absolute; top: 125px; z-index: 20000; left: 320px;}
#layerSelect2  {position: absolute; top: 340px; left: 20px; z-index: 10000;}
#overlaySelect2  {position: absolute; top: 240px; left: 0px; z-index: 10000;}
#zoomtoextent2 {position: absolute; top: 250px; left: 0px; z-index: 10000;}
#key {position: absolute; top: 130px; left: 11px; z-index: 10000;}

#map form {
	margin: 0;
	padding: 0;
}


#nlsgaz { 
	width: 150px;
	}

#ngrgaz { 
	width: 120px;
	font-size: 0.9em;
	}

#search-button-ngrgaz {
	float:left;
	margin: -28px 0 0 125px;
	vertical-align: top;
	width:20px;
	padding: 2px 3px 2px 7px;
	border: 1px;
	// color:#FFFFFF;
	color:#f3f3f3;
	font-size: 0.8em;
	border: 1px solid #0000FF; box-shadow: 0 1px 3px #ccc; 
	background-color: #FFF;
	font-weight:700;
	opacity: 0.95;
	z-index: 100;
        font-family: inherit;
	cursor: pointer;
}

/* CSS autocomplete */
.ac-renderer{position:absolute;border:1px solid #898989;z-index: 30000;margin-top:-1px;max-width:500px; max-height: 400px; overflow: auto; font-size:.9em;}

.ac-row{white-space:nowrap;position:relative;cursor:pointer;padding:5px;background-color:#fff;overflow:hidden !important; text-overflow:ellipsis}
.ac-row .suffix{font-size:.8em;color:#7a7a7a;padding:.1em 0 0 5px}
.ac-row .type{font-size:.8em;color:#aaa;display:block;width:100%}
.ac-highlighted{font-weight:bold}
.ac-active{color:#393939;background-color:#D6D6D6;}
.ac-type{background-color:#990033;color:#FFFFFF;display:block;margin:2px;padding:2px;font-style:italic;float:right}





#customZoom {
    z-index: 1001;
    position: relative;
    top: 10px;
    left: 10px;
}
#customZoom a {
    text-decoration: none;
    position: absolute;
    display: block;
    width: 50px;
    text-align: center;
    font-weight: bold;
    color: #fff;
    background: #369;
    border: 1px solid #ccc;
    border-radius: 3px;
}
#customZoom a:hover {
    background: #036;
}
#customZoomOut {
    top: 25px;
}

/* OpenLayers style.mobile.css */

div.olControlZoom {
    position: absolute;
    top: 8px ;
    left: 8px;
    background: rgba(255,255,255,0.4);
    border-radius: 4px;
    padding: 2px;
    margin: 1px;
}
* {
    -webkit-tap-highlight-color: rgba(0, 0, 0, 0);
}
div.olControlZoom a {
    display: block;
    margin: 1px;
    padding: 0;
    color: white;
    font-size: 28px;
    font-family: sans-serif;
    font-weight: bold;
    text-decoration: none;
    text-align: center;
    height: 32px;
    width: 32px;
    line-height: 28px;
    text-shadow: 0 0 3px rgba(0,0,0,0.8);
    background: #130085; /* fallback for IE - IE6 requires background shorthand*/
    background: rgba(0, 60, 136, 0.5);
    filter: alpha(opacity=80);
}
a.olControlZoomIn {
    border-radius: 4px 4px 0 0;
}
a.olControlZoomOut {
    border-radius: 0 0 4px 4px;
}
div.olControlZoom a:hover {
    background: #130085; /* fallback for IE */
    background: rgba(0, 60, 136, 0.7);
    filter: alpha(opacity=100);
}
@media only screen and (max-width: 600px) {
    div.olControlZoom a:hover {
        background: rgba(0, 60, 136, 0.5);
    }
}
.olLayerGrid .olTileImage {
    -webkit-transition: opacity 0.2s linear;
    -moz-transition: opacity 0.2s linear;
    -o-transition: opacity 0.2s linear;
    transition: opacity 0.2s linear;
}






#mapViewerSideBySide #NLSLogo {
	padding: 6px 16px;
}


#mapViewerSideBySide #siteTitle {
	padding: 10px 0 0 18px;
}

#mapViewerSideBySide #return, #mapViewerSideBySide #zoomtoextent {
	position: absolute;
	right: 5px;
	padding: 0;
	margin: 0;
}

#mapViewerSideBySide #zoomtoextentleft {
	position: absolute;
	top: 95px;
  	right: 52%;
	font-size: 0.8em;
	overflow: hidden;
}

#mapViewerSideBySide #zoomtoextentright {
	position: absolute;
	top: 95px;
  	right: 2%;
	font-size: 0.8em;
	overflow: hidden;
}

#mapViewerSideBySide #return {
	top: 5px;
	font-size: 0.8em;
}

#mapViewerSideBySide #zoomtoextent, #overlaySelectNode, #overlaySelectLayer, #overlaySelectNodeRight, #overlaySelectLayerRight {
	top: 40px;
	font-size: 0.9em;
	overflow: hidden;
}

#overlaySelectNode,  #overlaySelectNodeRight {
	margin: 0 140px 0 0px;
}

#mapViewerSideBySide #mapleft, #mapViewerSideBySide #mapright {
	top: 0px;
	bottom: 0;
}

#mapViewerSideBySide #mapleft {
	left: 0;
	right: 50.2%;
	border-right: 1px solid #ccc;
}

#mapViewerSideBySide #mapright {
	right: 0;
	left: 49.9%;
	border-left: 1px solid #ccc;
}

#mapViewerSideBySide #searchSideBar {
	clear: both;
	-moz-box-shadow: none;
	-webkit-box-shadow: none;
	box-shadow: none;
}

#mapViewerSideBySide #searchSideBar #nlsmapleftform, #mapViewerSideBySide #searchSideBar #nlsmaprightform {
	background-color: #eee;
	padding: 0.5%;
	max-height: 65px;
}

#mapViewerSideBySide #searchSideBar #nlsmapleftform {
	width: 48.5%;
	float: left;
}

#mapViewerSideBySide #searchSideBar #nlsmaprightform {
	width: 49.5%;
	float: right;
}

#mapViewerSideBySide #searchSideBar p {
	font-size: 0.9em;
	padding: 0;
}

/* BLOCKS WITH FLOATED CONTENT FIX */
/* These declarations make sure that the containers that contain nothing 
but floated elements expand to contain those floated elements */

#mapViewerSideBySide #searchSideBar:after{
    content: "."; 
    display: block; 
    height: 0; 
    clear: both; 
    visibility: hidden;
}

* html #mapViewerSideBySide #searchSideBar {
	height: 1%;
}

.olControlZoom { top:125px !important; }
.olControlOverviewMapElement { padding:0px !important; background-color:#999 !important; -moz-border-radius: 0px !important;}
.olControlOverviewMapExtentRectangle { border: 1px solid #f00 !important; }
.olImageLoadError { visibility: hidden; }
.olHandlerBoxZoomBox {
    border: 2px solid red;
    position: absolute;
    background-color: white;
    opacity: 0.50;
    font-size: 1px;
    filter: alpha(opacity=50);
}
.olControlOverviewMapRectReplacement { border: 1px solid #f00; }

	#mapViewerPrint #drawControlForm {
	    position: absolute;
	    right: 10px;
	    top: 5px;
	    font-size: 12px;
	    display: inline !important;
	}

	#mapViewerPrint #drawControlForm2 {
	    position: absolute;
	    right: 10px;
	    top: 35px;
	    font-size: 12px;
	    display: inline !important;
	}



	#mapViewerGeoRefMaps #stopmeasuringmessage {
	    right: 230px;
	    top: 125px;
	}

	#mapViewerPrint #stopmeasuringmessage {
	    right: 130px;
	    top: 94px;
	}

	#mapViewerPrint #header #pageTitle {
	   margin-right:180px;
	}

      .ol-popup {position: absolute;background-color: white;-webkit-filter: drop-shadow(0 1px 4px rgba(0,0,0,0.2));filter: drop-shadow(0 1px 4px rgba(0,0,0,0.2));
        padding: 15px;border-radius: 10px;font-size: 12px; border: 1px solid #cccccc; bottom: 12px; left: -50px; min-width: 280px;  z-index: 2000000;}
      .ol-popup:after, .ol-popup:before {top: 100%;border: solid transparent;content: " ";height: 0;width: 0;position: absolute;pointer-events: none;text-decoration: none;}
      .ol-popup:after {border-top-color: white; border-width: 10px;left: 48px;margin-left: -10px;}
       a { text-decoration: none; }
      .ol-popup:before {border-top-color: #cccccc;border-width: 11px;left: 48px;margin-left: -11px;}
      .ol-popup-closer {text-decoration: none; position: absolute;top: 2px;right: 8px;}
      .ol-popup-closer:after { content: "Close";}



		.close {
			    -webkit-appearance: none;
			    padding: 0;
			    cursor: pointer;
			    background: 0 0;
			    border: 0;
			    float: right;
			    font-size: 16pt;
			    font-weight: 700;
			    line-height: 1;
			    color: #000;
			    text-shadow: 0 1px 0 #fff;
			    filter: alpha(opacity=20);
			    opacity: .6;
			}

			.close:hover {
			    opacity: 0.2;
			}


/* The Modal (background) */
.modal {
    display: none; /* Hidden by default */
    position: fixed; /* Stay in place */
    z-index: 100000000; /* Sit on top */
    left: 0;
    top: 0;
    width: 100%; /* Full width */
    height: 100%; /* Full height */
    overflow: auto; /* Enable scroll if needed */
    background-color: rgb(0,0,0); /* Fallback color */
    background-color: rgba(0,0,0,0.4); /* Black w/ opacity */
}

/* Modal Content/Box */
.modal-content {
    background-color: #fefefe;
    margin: 15% auto; /* 15% from the top and centered */
    padding: 15px;
    border: 1px solid #888;
    width: 80%; /* Could be more or less, depending on screen size */
}

#modal-text { z-index: 0; padding: 25px;}

/* The Close Button */
.modal-close {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
    z-index: 1;
}

.modal-close:hover,
.modal-close:focus {
    color: black;
    text-decoration: none;
    cursor: pointer;
}
