*, *:before, *:after { box-sizing: border-box; }

:root{
    --xpgreen: #00943f;
    --text-color: black;
}

body, html {
    margin: 0;
    padding: 0;
    height: 100vh;
    width: 165vw; 
    overflow-x: auto; /* i think its the horizontal thing */
    overflow-y: hidden; /* and this for no verticality? */
    background: transparent;
  }
  
  body {
    display: flex;
    flex-direction: row;
  }

  .background-image {
    position: absolute;
    top: 50%;
    left: 75%;
    transform: translate(-50%, -50%);
    width: 140vw;
    height: 140vh;
    background-image: url('carto.png');
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
    z-index: -1;
    pointer-events: none;
  }

  .subtitle-text-left {
    position: absolute;
    top: 50%;
    left: 5%;
    transform: translate(0, -50%);
    font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
    font-size: 2em;
    color: yellow;
    z-index: 1;
    text-align: left;
    pointer-events: none;
    white-space: nowrap;
  }

  .subtitle-text-right {
    position: absolute;
    top: 50%;
    left: calc(75% + 75vw);
    transform: translate(-50%, -50%);
    font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
    font-size: 2em;
    color: yellow;
    z-index: 1;
    text-align: center;
    pointer-events: none;
    white-space: nowrap;
  }

 
  .scrolling-text-top {
    position: fixed;
    top: 5%;
    left: 0;
    width: 150vw;
    overflow: hidden;
    white-space: nowrap;
    z-index: 0;
    pointer-events: none;
  }

  .scrolling-text-top span {
    display: inline-block;
    animation: scroll-left 20s linear infinite;
    font-size: 1.2em;
    color: #0066cc;
    font-weight: bold;
  }

  /* Texte défilant en bas */
  .scrolling-text-bottom {
    position: fixed;
    bottom: 5%;
    left: 0;
    width: 150vw;
    overflow: hidden;
    white-space: nowrap;
    z-index: 0;
    pointer-events: none;
  }

  .scrolling-text-bottom span {
    display: inline-block;
    animation: scroll-right 20s linear infinite;
    font-size: 1.2em;
    color: #0066cc;
    font-weight: bold;
  }

  /* texte défilant à gauche */
  .scrolling-text-left {
    position: fixed;
    left: 2%;
    top: 0;
    height: 100vh;
    writing-mode: vertical-rl;
    overflow: hidden;
    white-space: nowrap;
    z-index: 0;
    pointer-events: none;
  }

  .scrolling-text-left span {
    display: inline-block;
    animation: scroll-down 20s linear infinite;
    font-size: 1.2em;
    color: #0066cc;
    font-weight: bold;
  }

  /* texte défilant à droite */
  .scrolling-text-right {
    position: fixed;
    right: 2%;
    top: 0;
    height: 100vh;
    writing-mode: vertical-rl;
    overflow: hidden;
    white-space: nowrap;
    z-index: 0;
    pointer-events: none;
  }

  .scrolling-text-right span {
    display: inline-block;
    animation: scroll-up 20s linear infinite;
    font-size: 1.2em;
    color: #0066cc;
    font-weight: bold;
  }

  @keyframes scroll-left {
    0% { transform: translateX(0); }
    100% { transform: translateX(-50%); }
  }

  @keyframes scroll-right {
    0% { transform: translateX(-50%); }
    100% { transform: translateX(0); }
  }

  @keyframes scroll-down {
    0% { transform: translateY(0); }
    100% { transform: translateY(-50%); }
  }

  @keyframes scroll-up {
    0% { transform: translateY(-50%); }
    100% { transform: translateY(0); }
  }


  .content {
    position: relative;
    z-index: 1;
    color: white;
    text-align: center;
    top: 40%;
    width: 150vw;
    min-width: 150vw;
  }

  header {
    color: blue;
    font-size: 1.5em;
  }


/* THE TOOLS */

.tools {
	display: block;
	
	z-index: 1;
}

.tool {
	
	cursor: cell;
	position: absolute;
	width: 4vw;
	min-width: 40px;
	display: block;
	transform: translate(-50%, -50%);
	z-index: 0;
	transition: 0.1s;
}

#tool5-link {
  transform: translate(-50%, -50%) scale(1.2);
}

#toolacid-link {
  transform: translate(-50%, -50%) scale(1.2);
}

#toolacid-link .tool-icon {
  position: relative;
  top: -30px;
  left: 25px;
  width: 1.2em;
}

#toolwind-link {
  transform: translate(-50%, -50%) scale(0.5);
}

#toolwind-link .tool-icon {
  position: relative;
  top: -40px;
  left: 30px;
}

.tool-background {
	position: absolute;
	width: 300%;
	min-width: 15vh;
	z-index: 0;
	transform: translate(-33%, -33%);
}

#tool5-link .tool-background {
	width: 300%;
	transform: translate(-33%, -33%);
}

.tool-icon {
	position: relative;
	width: inherit;
	min-width: 5vh;
	z-index: 1;
	transition: 0.1s;
}


.tool:hover {
	/* -webkit-filter: drop-shadow(0px 0px 10px floralwhite); */
	/* filter: drop-shadow(0px 0px 5px floralwhite); */   
	z-index: 4;
}


.tool:hover .tool-icon{
	width: 12vw;
	margin-left:-4vw;
	margin-top:2vh;
	z-index: 4;
}


/* THE POPUPS */

.popup {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  z-index: 999;
  visibility: hidden;
  opacity: 0;
  pointer-events: none;
  transition: all 0.1s;
  font-size: 1.4em;
  color: var(--text-color);
  font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;

}
.popup:target {
	visibility: visible;
    opacity: 1;
    pointer-events: auto;
}
a.back {
	display: block;
	height: 100vh;
	width: 165vw;
	position: absolute;
	top: 0;
	left: 0;
}

.popup > div {
	width: 300px;
	max-width: 90vw;
	position: absolute;
	top: 25%;
	left: 35%;
	transform: translate(-50%, -50%);
	padding: 1.5em;
	/* padding-bottom: 0; */
	background: floralwhite;
	text-align: center;
	height: 65vh;
	max-height: 90vh;
	overflow-y: scroll;
	cursor: initial;
}

/* Position TEMPOratur popup à côté du tool2 (left: 18%; top: 5%) */
#TEMPOratur > div {
	left: max(2%, 15%);
	top: 45%;
	transform: translate(0, -50%);
}

/* Position tool1 popup à côté du tool1 (left: 72%; top: -28%) */
#tool1 > div {
	left: auto;
	right: max(2%, 10%);
	top: 32%;
	transform: translate(0, 0);
}

/* Position tool5 popup à côté du tool5 (left: 40%; top: 30%) */
#tool5 > div {
	left: clamp(2%, 35%, calc(100% - 300px - 2%));
	top: 70%;
	transform: translate(0, -50%);
}

/* Position toolacid popup à côté du toolacid (left: 65%; top: 10%) */
#toolacid > div {
	left: 60%;
	top: 50%;
	transform: translate(0, -50%);
}

/* Position toolwind popup à côté du toolwind (left: 50%; top: 50%) */
#toolwind > div {
	left: 40%;
	top: 35%;
	transform: translate(0, -50%);
}

.shadow {
	background-color: rgba(0,0,0,0.1);
}

:root{
	--cardwidth: 90vw;
}

.card-close {
  color: #aaa;
  line-height: 50px;
  font-size: 70%;
  font-family: Arial, Helvetica, sans-serif;
  position: absolute;
  right: 0;
  top: 0;
  width: 3em;
  text-decoration: none;
}

.card-image{
	width: 100%;
	height: auto;
	display: block;
	margin: auto;
}

/* thats to reduce the image of tool5 in the popup i think*/
#tool5 .card-image {
	width: 50%;
}
.white{
	background-color: darkgreen;
}

.popup h2 {
	font-size: 1.2em;
	text-transform: capitalize;
	font-weight: normal;
}

.popup p{
	font-size: 0.8em;
}

h3 {
	font-size: 0.6em;
	font-weight: 100;
	text-transform: uppercase;
	letter-spacing: 0.1em;
}

h5 {
	font-family: 'Times New Roman', Times, serif;
	font-weight: 100;
	font-size: 0.6em;
	color: rgba(0,0,0,0.6);
	margin-top: 5px;;
}
