@import url('https://fonts.googleapis.com/css2?family=Roboto:wght@300;400&display=swap');


body {
	font-family: Roboto, Arial, sans-serif;
	font-weight: 500;
	background-image: linear-gradient(to bottom, rgba(255, 255, 255, 0.80), rgba(255, 255, 255, 0.40)), url('img/MeteoHilversumBackground2.jpg');
	background-size: cover;	/* adjusts the image size to cover the entire body */
	background-repeat: no-repeat;	/* prevents the background image from repeating */
	background-attachment: fixed;	/* fixes the background image in place */
}


/* Styles for the scroll back to the top button */
#scrollBtn {
	display: none;
	position: fixed;
	bottom: 20px;
	right: 20px;
	z-index: 99;
	font-size: 18px;
	border: none;
	outline: none;
	background-color: rgba(51, 51, 51, 0.3);	/* semi-transparent background */
	color: rgba(255, 255, 255, 0.7);	/* semi-transparent white text */
	cursor: pointer;
	padding: 10px;
	border-radius: 50%;
	transition: background-color 0.3s ease;
}

#scrollBtn:hover {
	background-color: rgba(51, 51, 51, 0.5);	/* darker semi-transparent background on hover */
	color: rgba(255, 255, 255, 0.9);	/* darker semi-transparent white text on hover */
}


/* Container div */
.container {
	max-width: 1030px;
	margin: 0 auto;
}


/* Title-bar div */
.header-div {
	width: 100%;
	height: max-content;
	border: 1px solid rgba(47, 47, 170, 0.644);
	border-radius: 10px;
	box-sizing: border-box;
	margin-bottom: 10px;
	display: flex;
	align-items: center;
	justify-content: center;
	text-align: center;
	flex-direction: column;
	/* Stack items vertically */
	font-size: 60px;
	font-weight: 600;
	padding: 8px 20px;
	background-color: white;
}

.header-div img {
	max-width: 100%;
}

.subtext-header {
	font-size: 30px;
	font-weight: 100;
	display: block;
}



/* Stuff in between the header and the main div */

.second-header-wrapper {
	display: flex;
	justify-content: space-between;
}

.header-div2 {
	/* Align contents to the left */
	font-size: 13px;
	text-align: left;
	display: flex;
	align-items: center;
	padding-left: 15px;
	padding-right: 15px;
}

.header-div3 {
	/* Align contents to the right */
	font-size: 13px;
	text-align: right;
	display: flex;
	align-items: center;
	padding-left: 15px;
	padding-right: 15px;
	justify-content: flex-end;
}

/* Arrow images in live data */
.sub-div-inhoud .weerPijl {
	display: inline-block;
	width: auto;
	height: 16px;
	margin-left: 3px;
	vertical-align: middle;
}

.sub-div-inhoud .windrichtingImg {
	width: fit-content;
	height: 16px;
	display: inline-block;
	vertical-align: middle;
	margin-left: 3px;
}

#windRichtingTekst {
	font-size: 16px;
}


/* Other */

.overig {
	height: 100%;
	width: 100%;
	align-items: center;
	justify-content: center;
	text-align: center;
	font-size: 15px;
}



/* footer-bar div */
.footer-div {
	width: 100%;
	border: 1px solid rgba(47, 47, 170, 0.644);
	border-radius: 10px;
	box-sizing: border-box;
	margin-top: 10px;
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	align-items: center;
	text-align: center;
	background-color: white;
	font-size: 12px;
	padding: 8px;
	line-height: 1.5;
}

/* Stuff in between the main div and the footer */
.footer-div2 {
	width: 100%;
	font-size: 13px;
	text-align: center;
	display: flex;
	justify-content: center;
	align-items: center;
	padding-top: 12px;
	padding-left: 15px;
	padding-right: 15px;
}


/* Main-div for all sub-divs, containing the weather data */
.main-div {
	width: 100%;
	border: 1px solid rgba(47, 47, 170, 0.644);
	border-radius: 10px;
	padding: 20px;
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	margin-top: 10px;
	box-sizing: border-box;
	gap: 20px;
}


/* Div for the title above sub-div-inhoud (inhoud = content) */
.sub-div-titel {
	margin-top: 0px;
	text-align: center;
	font-size: 18px;
	font-weight: 600;
}

/* Div for the second title line above sub-div-inhoud (inhoud = content)  */
.sub-div-titel2 {
	margin: 2px 0 5px;
	text-align: center;
	font-size: 11px;
	font-family: 'Roboto', sans-serif;
	font-weight: 10;
}

.sub-div-weerData {
	max-width: 315px;
	width: 100%;
	display: flex;
	flex-direction: column;
	margin-bottom: 30px;
}


/* Default width for weerkaart (= weather map) is 315px */
.sub-div-weerKaart {
	max-width: 315px;
	width: 100%;
	margin-bottom: 30px;
}


/* Div containing the weather data (inhoud = content) */
.sub-div-inhoud {
	box-sizing: border-box;
	max-width: 315px;
	max-height: 315px;
	width: 100%;
	height: auto;
	border: 1px solid lightgrey;
	border-radius: 10px;
	text-align: center;
	box-shadow: 0 3px 10px rgb(0 0 0 / 0.3);
	background-color: white;
}


.sub-div-weerData .sub-div-inhoud {
	padding: 4px;
	height: 100%;
	max-height: unset;
	min-height: 120px;
}


/* KNMI = Royal Dutch Meteorological Institute  */
/* KNMI divs for weather alarm data */
.sub-div-knmi {
	width: 100%;
	display: flex;
	flex-direction: column;
	margin-bottom: 30px;
}

.knmi-div-inhoud {
	box-sizing: border-box;
	width: 100%;
	height: auto;
	border: 1px solid lightgrey;
	border-radius: 10px;
	text-align: center;
	box-shadow: 0 3px 10px rgb(0 0 0 / 0.3);
	background-color: white;
	padding: 10px 20px 10px 20px;
	line-height: 1.2;
}

.knmi-div-inhoud p:not(.knmi-tijd) {
	font-weight: 700;
	font-size: 11px;
}

.knmi-tijd {
	font-size: 10px;
	font-style: italic;
}



/* Divs for the 72h graph */
.sub-div-grafiek {
	width: 100%;
	display: flex;
	flex-direction: column;
	margin-bottom: 30px;
}

.grafiek-div-inhoud {
	box-sizing: border-box;
	width: 100%;
	height: auto;
	border: 1px solid lightgrey;
	border-radius: 10px;
	text-align: center;
	box-shadow: 0 3px 10px rgb(0 0 0 / 0.3);
	background-color: white;
	padding: 10px 10px 10px 0px;
	line-height: 1.2;
}



/* Style for showing is info current (is it "up" or "down") dots in the footer  */
.dot {
	height: 12px;
	width: 12px;
	border-radius: 50%;
	display: inline-block;
	margin-right: 8px;
	vertical-align: middle;
}

.up {
	background-color: #71D63B;
}

.down {
	background-color: red;
}




/* Style for the display archive option */
/* CSS for modal */
.modal {
	display: none;	/* Hide the modal by default */
	position: fixed;	/* Position the modal */
	top: 0;
	left: 0;
	width: 100%;	/* Full width */
	height: 100%;	/* Full height */
	background-color: rgba(0, 0, 0, 0.5);	/* Semi-transparent black background */
	z-index: 9999;	/* Ensure it's on top of other elements */
	overflow: auto;	/* Enable scrolling if content overflows */
}

.modal-content {
	background-color: #fefefe;
	margin: 10% auto;	/* Center the modal content */
	padding: 20px;
	border: 1px solid #888;
	width: 100%;
	max-width: 800px;
	;
}

/* CSS for the specific iframe inside the modal */
#modalIframe {
	width: 100%;
	height: 60vh;
}




/* Style for displaying images in the Weather Maps section */
.sub-div-inhoud img {
	display: block;
	width: 100%;
	height: 100%;
	border-radius: 10px;
	object-fit: cover;
}

.sub-div-weerKaart .sub-div-inhoud img {
	height: 100%;
	min-height: 313px;
}

.weerkaartRechthoek .sub-div-inhoud {
	box-sizing: border-box;
	max-width: 315px;
	width: 100%;
	height: 0;
	padding-bottom: 100%;
	border: 1px solid lightgrey;
	border-radius: 10px;
	overflow: hidden;
	position: relative;
}

.weerkaart-img-container {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
}

.weerkaart-img-container img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
	object-position: left;
	border-radius: 10px;
}


/* Style for weather map 5 of 6, luchtdrukkaart (= air pressure map) */
.sub-div-inhoud2 {
	box-sizing: border-box;
	max-width: 315px;
	width: 100%;
	max-height: 315px;
	height: auto;
	border: 1px solid lightgrey;
	border-radius: 10px;
	overflow: hidden;
	position: relative;
	box-shadow: 0 3px 10px rgb(0 0 0 / 0.3);
}

.sub-div-inhoud2::before {
	content: "";
	display: block;
	padding-top: 100%;
}

/* Style for weather map 5 of 6, luchtdrukkaart (= air pressure map), with settings to only show a specific portion of the map */
.sub-div-inhoud2 img {
	display: block;
	border-radius: 10px;
	object-fit: cover;
	object-position: 70% center;
	position: relative;
	top: 55%;
	left: 50%;
	position: absolute;
	transform: translate(-50%, -50%) scale(1.11);
	height: 100%;
	width: 100%;
}


/* Style for weather map 1 of 6, with settings to only show a specific portion of the map */
#updateRadar {
	width: 500px;
	height: 500px;
	overflow: hidden;
	/* This will hide content outside the div */
	position: relative;
	/* Ensure the iframe stays within the div */
}

#updateRadar iframe {
	position: relative;
	object-fit: cover;
	left: 53%;
	transform: translateX(-50%) translateY(-11%);
	width: 100px;
	height: 100px;
	padding: 0px;
	border: none !important;
	box-sizing: border-box !important;
}


/* Style for weather map 2 of 6, with settings to only show a specific portion of the map */
#updateSatelliet {
	width: 500px;
	height: 500px;
	overflow: hidden;
	/* This will hide content outside the div */
	position: relative;
	/* Ensure the iframe stays within the div */
}

#updateSatelliet iframe {
	position: relative;
	object-fit: cover;
	left: 53%;
	transform: translateX(-50%) translateY(-11%);
	width: 100px;
	height: 100px;
	padding: 0px;
	border: none !important;
	box-sizing: border-box !important;
}



/* Style for weather map 3 of 6, with settings to only show a specific portion of the map */
/* Still contains the word "Verwachting" (forecast), but this is now actually displays the map of Hilversum */
#updateRadarVerwachting {
	width: 500px;
	height: 500px;
	overflow: hidden;
	/* This will hide content outside the div */
	position: relative;
	/* Ensure the iframe stays within the div */
}

#updateRadarVerwachting iframe {
	position: relative;
	object-fit: cover;
	left: 53%;
	transform: translateX(-50%) translateY(-11%);
	width: 100px;
	height: 100px;
	padding: 0px;
	border: none !important;
	box-sizing: border-box !important;
}



/* Style for weather map 4 of 6, with settings to only show a specific portion of the map */
#updateRadarEuropa {
	width: 500px;
	height: 500px;
	overflow: hidden;
	/* This will hide content outside the div */
	position: relative;
	/* Ensure the iframe stays within the div */
}

#updateRadarEuropa iframe {
	position: relative;
	object-fit: cover;
	left: 53%;
	transform: translateX(-50%) translateY(-11%);
	width: 100px;
	height: 100px;
	padding: 0px;
	border: none !important;
	box-sizing: border-box !important;
}






/* Style for weather map 6 of 6, the windkaart (= wind map), with settings to only show a specific portion of the map, also creating a transparant overlay to prevent direct interaction with the iframe */
#updateWind {
	position: relative;
	border-radius: 10px;
	overflow: hidden;
}

.weerkaartWind .sub-div-inhoud {
	box-sizing: border-box;
	width: 100%;
	height: 0;
	padding-bottom: 100%;
	position: relative;
	overflow: hidden;
}

.windKaart-img-container {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
}

.weerkaartWind .windKaart-img-container iframe {
	display: block;
	/*width: 100%;
	height: 100%;*/
	border: 0;
	pointer-events: none;
	top: -60px;
	left: -65px;
	width: 440px;
	/* Set the width of the iframe content in the 315px div frame */
	height: 440px;
	/* Set the height of the iframe content  in the 315px div frame*/
	position: absolute;
}





/* Only show the middle part of the radar maps */
.iframe-voor-radar {
	width: 315px;
	height: 315px;
	overflow: hidden;
	position: relative;
}

.iframe-voor-radar .weerslag-.iframe {
	width: 370px;
	/* Set the width of the iframe content in the 315px div frame */
	height: 370px;
	/* Set the height of the iframe content in the 315px div frame */
	position: absolute;
	top: -40px;
	/* Adjust to show the center of the iframe */
	left: -15px;
	/* Adjust to show the center of the iframe */
	clip: rect(0px, 10px, 10px, 10px);
	/* Define the portion to display (top, right, bottom, left) */
}






/* Style for displaying primary (every 10 seconds) and secondary (every 5 minutes) weather data */
.datacontainer {
	display: flex;
	flex-direction: column;
	align-items: center;
	height: 100%;
	justify-content: flex-end;
	gap: 30px;
}

.actuele-weerData-div .datacontainer {
	justify-content: center;
}

.actuele-weerData-div .sub-div-inhoud {
	padding: 10px;
}

.weerData-live-container {
	display: flex;
	flex-direction: column;
	justify-content: center;
	gap: 10px;
	padding: 7px 0px 3px 0px;
}

.data-chart {
	max-height: 56px;
	height: 100%;
}

.data-chart-zon .data-title-extra {
	display: flex;
	align-items: baseline;
	justify-content: space-evenly;
}

.data-chart canvas {
	max-width: 100%;
	width: 100%;
}

.data-title-main {
	font-size: 25px;
	text-align: center;
	font-weight: 400;
}

/* Prevent <sup> from adjusting the line height */
.data-title-main sup {
	vertical-align: top;
	font-size: smaller;
}

.data-title-extra {
	font-size: 14px;
	text-align: left;
	display: flex;
	align-items: center;
}

.overig {
	height: 315px;
	font-size: 12px;
	text-align: left;
}

.wd-data {
	display: table;
	max-width: 300px;
	width: 100%;
	border-spacing: 3px 0px;
	padding: 3px 0px 3px 0px;
}

.wd-data-row {
	display: table-row;
}

.wd-data .wd-data-row:first-child div {
	border-radius: 3px 3px 0px 0px;
	background-color: #4682b4;
	text-transform: uppercase;
	color: white;
}

.wd-data .wd-data-row:last-child div {
	border-radius: 0px 0px 3px 3px;
}

.wd-data .wd-data-row:nth-child(even) div {
	background-color: #ebebeb;
}

.wd-data .wd-data-row:not(:first-child):nth-child(odd) div {
	background-color: white;
}

.wd-data .wd-data-row:not(:first-child) .wd-data-cell-titel {
	padding-left: 5px;
	text-align: left;
}

.wd-data-cell-titel {
	display: table-cell;
	padding: 4px 2px;
	font-size: 11px;
	font-family: 'Roboto', sans-serif;
	vertical-align: middle;
}

.wd-data-cell {
	display: table-cell;
	padding: 4px 2px;
	font-size: 11px;
	font-family: 'Roboto', sans-serif;
	vertical-align: middle;
}


/* Prevent <sup> from adjusting the line height */
.wd-data-cell sup {
	vertical-align: top;
	font-size: smaller;
}

/* link-style */
a {
	color: black;
	text-decoration: none;
}

a:hover {
	text-decoration: underline;
}


hr {
	height: 1px;
	background-color: grey;
	border: none;
}


/* Graphs */
.sub-div-weerGrafiek {
	max-width: 315px;
	width: 100%;
	margin-bottom: 30px;
}



.weerGrafiekCanvas {
	display: flex;
	align-items: center;
	justify-content: center;
	max-width: 315px;
	max-height: 3150px;
	width: 100%;
	height: 100%;
}

.weerGrafiekCanvas canvas {
	max-width: 100%;
	max-height: 100%;
}

/*Media Queries*/
@media screen and (max-width: 1060px) {
	.knmi-div-inhoud {
		max-width: 650px;
		margin: 0 auto;

	}
}

@media screen and (max-width: 725px) {
	.knmi-div-inhoud {
		max-width: 315px;
		margin: 0 auto;
	}
}


@media screen and (max-width: 1060px) {
	.grafiek-div-inhoud {
		max-width: 650px;
		margin: 0 auto;
	}
}

@media screen and (max-width: 725px) {
	.grafiek-div-inhoud {
		max-width: 315px;
		margin: 0 auto;
	}

	#scrollBtn {
		color: rgb(255, 255, 255);
		/* non-transparent white text */
		font-weight: bold;
	}

	#scrollBtn:hover {
		color: rgb(255, 255, 255);
		/* non-transparent white text */
		font-weight: bold;
	}
}



@media screen and (max-width: 390px) {
	.main-div {
		padding: 10px;
	}

	.header-div {
		font-size: 40px;
	}

	.subtext-header {
		font-size: 20px;
	}

	.second-header-wrapper {
		flex-direction: column;
	}

	.header-div2 {
		padding-bottom: 5px;
	}

	.header-div3 {
		text-align: right;
	}

	.data-title-main {
		font-size: 35px;
	}

	.weerData-live-container {
		padding-top: 20px;
	}

	.datacontainer {
		gap: 20px;
	}

	.sub-div-weerData .sub-div-inhoud {
		min-height: unset;
	}

	.sub-div-titel {
		margin-top: 20px;
	}

	.sub-div-weerGrafiek:last-child {
		margin-bottom: 20px;
	}

	.sub-div-weerData {
		margin-bottom: 0px;
	}

	.sub-div-knmi {
		margin-bottom: 0px;
	}

	.sub-div-grafiek {
		margin-bottom: 0px;
	}

	.sub-div-weerKaart {
		margin-bottom: 0px;
	}

	.sub-div-weerGrafiek {
		margin-bottom: 0px;
	}

	#scrollBtn {
		color: rgb(255, 255, 255);
		/* non-transparent white text */
		font-weight: bold;
	}

	#scrollBtn:hover {
		color: rgb(255, 255, 255);
		/* non-transparent white text */
		font-weight: bold;
	}


}


/* Tooltips for the graphs */
.tooltip {
	position: relative;
	display: inline-block;
}

.tooltip .tooltiptext {
	visibility: hidden;
	width: 330px;
	background-color: rgba(155, 36, 36, 0.95);
	color: white;
	font-weight: 500;
	border: 1px solid black;
	text-align: center;
	border-radius: 6px;
	padding: 5px;
	position: absolute;
	z-index: 1;
	bottom: 90%;
	left: 50%;
	transform: translateX(-50%);
	opacity: 9;
	transition: opacity 0.3s;
	font-size: 13px;
}

.tooltip:hover .tooltiptext {
	visibility: visible;
	opacity: 1;
}


/* Blinking notification in mededeling.txt */
    .fade-blink {
      color: red;
      animation: fade-blink-animation 5.5s ease-in-out infinite;
    }

    @keyframes fade-blink-animation {
      0%, 61.54% {
        opacity: 1; /* Visible for 4 seconds */
      }
      76.92% {
        opacity: 0; /* Fading out */
      }
      92.31% {
        opacity: 1; /* Fading back in */
      }
      100% {
        opacity: 1; /* Remains visible */
      }
    }