@import url('https://fonts.googleapis.com/css?family=Libre+Franklin:400,700|Montserrat:400,700');

:root {

	/* Colors */
	--color-primary: #c62828;
	/*#aaa;*/
	/*#4a4a4a;*/


	/* Fonts */
	--font-primary: "Libre Franklin", sans-serif;
	--font-secondary: 'Lato', sans-serif;
	--font-teritary: 'Montserrat', sans-serif;

	--letter-spacing: 0.5px;
	--border-radius: 3px;
}


body {
	margin: 0;
}

a {
	color: var(--color-primary);
	text-decoration: none;
}



input {
	width: 95%;
}

/*-------------
GRID
--------------- */

.wrapper {
	max-width: 700px;
}


/*-------------
MAP
--------------- */

/* Needed for the map to appear */
#mapid { 
	height: 500px;
	width: 700px; 
}

.map__info {
	margin: 0 auto;
	padding: 24px;
}


.map__headline,
.map__subheadline {
	font-family: var(--font-primary);
}

.map__headline {
	margin: 0;
	font-weight: 700;
	color: #4a4a4a;
	/*margin-top: 24px;*/
}

.map__credit {
	font-family: var(--font-primary);
	color: grey;
	font-size: 12px;
}

.map__subheadline {
	font-size: 14px;
	margin-top: 4px;
	padding-bottom: 24px;
	border-bottom: 1px solid #ddd;
}

.map__subheadline span {
	font-style: italic;
}

/* Displays information when a polygon is clicked */
.map__sentence {
	font-family: var(--font-primary);
	/*font-size: 18px;*/
	font-size: 16px;
	margin-top: 0;
	/*margin-top: 32px;*/
	/*margin-bottom: 32px;*/
}

.map__sentence span {
	font-weight: 700;
}

.prompt {
	font-family: var(--font-primary);
	/*font-weight: 700;*/
	color: #4a4a4a;
	margin-bottom: 16px;
	margin-top: 16px;
}

/* This paragraph is hidden by default */
/*.map__sentence.is-hidden {
	display: none;
}
*/
/*-------------
OTHER
--------------- */
/*???*/
.info {
	background: white;
	font-family: var(--font-secondary);
	font-size: 14px;
	line-height: 1.8;
	border-radius: var(--border-radius);
	color: black;
	border: 2px solid black;
	max-width: 250px;
}


/*-------------
LEGEND
--------------- */

/* Legend title */
h4 {
	margin-top: 8px;
}

.legend {
	padding: 16px;
}

.map__legend {
	/*border: 1px solid blue;*/
	display: grid;
	grid-template-columns: repeat(2, 1fr);
	grid-column-gap: 16px;
	grid-row-gap: 16px;
	margin-bottom: 24px;

}

.legend__group {
	/*border: 1px solid red;*/
	display: flex;
	align-items: center;
}

.legend__group:hover {
	color: #c62828;
	cursor: pointer;
}

.legend__group:hover > .legend__value,
.legend__group:hover > .legend__value-group > .legend__value {
	border-bottom: 1px solid #c62828;
}

/*.legend__value-group:hover > .legend__value {
	border-bottom: 1px solid #c62828;
}*/

.legend__circle {
	background: #000;
	width: 20px !important;
	height: 20px !important;
	margin-right: 8px;
	border-radius: 50%;
	color: #fff;
	font-family: var(--font-secondary);
	font-size: 15px;
	text-align: center;
	font-weight: 700;
/*	margin-left: 0 !important;
	margin-right: 0 !important;*/
}

/*.legend__circle.is-red {
	background: #c62828;
}
*/
.legend__circle.is-selected {
	background: #c62828;
	/*border-bottom: 1px solid #c62828;*/
}


/*.leaflet-container {
	font: var(--font-secondary) !important;
}*/

.leaflet-popup-content {
	font-size: 14px;
	font-family: var(--font-primary);
}

.legend__square {
	background: #aaa;
	width: 15px;
	height: 15px;
	margin-right: 8px;
	opacity: 0.7;
	border: 1px solid #000;
}


/* Specific to this map */
.square-1 { background: #f7f7f7; }
.square-2 { background: #c6dbef; }
.square-3 { background: #9ecae1; }
.square-4 { background: #6baed6; }
.square-5 { background: #3182bd; }
.square-6 { background: #08519c; }

.legend__value {
	margin: 0;
	font-size: 14px;
	font-family: var(--font-primary);
	border-bottom: 1px solid #000;
	padding-bottom: 2px;
	line-height: 1.6;
}

.legend__value.is-selected {
	color: #c62828;
	border-bottom: 1px solid #c62828;
}


/*.legend__value:hover,
.legend__value-group:hover > .legend__value {
	border-bottom: 1px solid #c62828;
}*/

/* The tiny squares in the legend */
.legend i {
	width: 18px;
	height: 18px;
	border: 1px solid black;
	margin-right: 10px;
	float: left;
}

/* Legend attribution */
.source {
	margin-top: 8px;
	font-style: italic;
	line-height: 1.4;
}

@media (max-width: 700px) {
	#mapid {
		width: 100%;
	}
}

@media (max-width: 640px) {
	.legend__value {
		display: inline;
	}
}

@media (max-width: 480px) {
	.map__legend {
		grid-template-columns: 1fr;
	}
}