@import 'fonts.css';
@import 'variables.css';

/* general */

html {
  font-size: 16px;
  font-family: "Monument Grotesk";
}

body {
  overflow-x: hidden;
}

header {
  padding: var(--gap);
  box-sizing: border-box;
  width: 100%;
  height: 5rem;
  display: flex;
  justify-content: space-between;
}

h1 {
  font-family: "Ruder Plakat";
  font-size: 3rem;
  letter-spacing: 0.03em;
  line-height: 1;
  z-index: 2000;
}

main {
  padding: 0 var(--gap) 0 var(--gap);
  box-sizing: border-box;
  width: 100%;
  height: calc(100dvh - 5rem - 3rem);
}

article {
  width: 100%;
  height: 100%;
  scrollbar-width: none;
}

article::-webkit-scrollbar {
  display: none;
}

footer {
  font-family: 'IBM Plex';
  font-size: 0.85rem;
  padding: var(--gap);
  box-sizing: border-box;
  height: 3rem;
  width: 100%;
}

/* menu */

.menu {
  width: 100%;
  height: var(--menu-height);
  display: flex;
  margin-bottom: var(--negative-border-width);
  position: relative;
  z-index: 1600;
  justify-content: space-between;
}

.menu ul {
  display: flex;
}

.menu ul.main {
  width: calc(50vw - var(--gap) - var(--border-width));
}

.main .case a {
  display: flex;
  justify-content: center;
  align-items: center;
}

.main .case svg {
  height: 1.75rem;
  width: auto;
  transition: 0.25s;
}

.menu li {
  border-style: solid;
  border-color: black;
  border-width: var(--border-width);
  margin-right: var(--negative-border-width);
  transition: 0.2s;
}

.menu li.active {
  border-bottom: var(--border-width) solid transparent;
}

.menu a {
  display: block;
  box-sizing: border-box;
  height: 100%;
  white-space: nowrap;
}

a.active {
  text-decoration: underline;
  font-weight: bold;
}

.menu .chapter {
  overflow: hidden;
  background-color: var(--grey);
  width: 100%;
  max-width: 10em;
  min-width: var(--menu-height);
  padding: 0.5rem;
}

.menu .case-collection {
  justify-self: right;
}

.menu .case {
  width: var(--menu-height);
}

.menu .case:hover svg {
  transform: scale(1.1);
}

.menu button {
  width: var(--menu-height);
  height: var(--menu-height);
  background-color: var(--white);
  border: var(--border-width) solid black;
  text-align: center;
  box-sizing: border-box;
}

.menu button.active {
  border-bottom: 0 solid transparent;
  padding-bottom: var(--border-width);
}

nav.mobile {
  width: 100vw;
  background-color: var(--grey);
  height: 100%;
  position: fixed;
  left: 100vw;
  top: 0;
  z-index: 2000;
  font-size: 1.25rem;
  overflow-x: hidden;
  overflow-y: scroll;
  box-sizing: border-box;
  scrollbar-width: none;
}

nav.mobile.active {
  display: none;
}

nav.mobile::-webkit-scrollbar {
  display: none;
}

nav.mobile.active {
  left: 0;
}

.mobile a {
  display: flex;
  width: 100%;
  height: 100%;
  text-align: center;
  justify-content: center;
  align-items: center;
}

.mobile-sub a:hover {
  background-color: yellow;
}

.mobile-main {
  display: grid;
  grid-template-rows: 2fr 1fr 3fr 3fr auto 1fr 1fr 1fr 1fr;
  min-height: 60rem;
}

.mobile-sub {
  border-bottom: var(--border-width) solid black;
  display: flex;
  justify-content: center;
  align-items: center;
  flex-direction: row;
}

.mobile-sub:nth-child(4) {
  border-bottom: none;
}

.mobile-sub:last-child {
  border-bottom: none;
}

.mobile-sub:nth-last-child(-n+5) {
  font-family: 'IBM Plex';
  font-size: 0.85rem;
}

.mobile .subgrid {
  width: 100%;
  height: 100%;
  display: grid;
  grid-template-columns: 1fr 1fr 1fr 1fr;
}

.subgrid li {
  display: flex;
  justify-content: center;
  align-items: center;
  aspect-ratio: 1/1;
  overflow: hidden;
  outline: calc(1 * var(--border-width)) solid black;
  outline-offset: calc(-0.5 * var(--border-width));
}

.subgrid a {
  display: flex;
  justify-content: center;
  align-items: center;
}

.mobile-sub:has(.subgrid) {
  border-bottom: none;
}

.mobile-sub svg {
  height: 4rem;
  pointer-events: none;
}

.toggle-mobile {
  z-index: 3000;
  display: none;
}

button .close,
button.active .open {
  display: none;
}

button .open,
button.active .close {
  display: block;
}

button.info {
  display: flex;
  justify-content: center;
  align-items: center;
}

button .circle {
  display: flex;
  justify-content: center;
  align-items: center;
  background-color: black;
  color: white;
  font-family: 'IBM Plex';
  border-radius: 3em;
  width: 2em;
  height: 2em;
}

.languages ul {
  display: flex;
  flex-direction: row;
  gap: calc(2 * var(--gap));
  font-family: 'IBM Plex';
  font-size: 0.85rem;
  flex-wrap: wrap;
  justify-content: center;
}

.mobile .languages ul {
  padding: 1em;
}

footer nav ul {
  display: flex;
  flex-direction: row;
  justify-content: flex-end;
  gap: calc(2 * var(--gap));
  line-height: 1;
}

/* canvas */

.canvas {
  width: 100%;
  height: calc(100% - var(--menu-height) + var(--border-width));
  background-color: var(--grey);
  overflow: hidden;
  border-style: solid;
  border-color: black;
  border-width: var(--border-width);
  box-sizing: border-box;
  position: relative;
}

/* case-single */

#case-single .canvas {
  display: grid;
  grid-template-columns: 1fr 1fr;
}

#case-single .description {
  display: grid;
  width: 100%;
  height: 100%;
  grid-template-rows: 5rem auto 4rem;
}

/* description */

.description .slide-collection {
  overflow-x: scroll;
  display: flex;
  flex-direction: row;
  scroll-snap-type: x mandatory;
  -ms-overflow-style: none;
  scrollbar-width: none;
}

.description .slide-collection::-webkit-scrollbar {
  display: none;
}

.description .slide-single {
  width: calc(50vw - var(--gap));
  scroll-snap-align: start;
  flex-shrink: 0;
  display: flex;
  justify-content: center;
}

.description .slide-single .text {
  display: flex;
  padding: 1rem;
  font-size: 1.15rem;
  box-sizing: border-box;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  gap: 1em;
  max-width: 28em;
}

.text p {
  text-wrap: balance;
}

.text h3 {
  font-weight: 500;
}

/* counter */

.counter {
  display: grid;
  grid-template-columns: 2rem 4rem 2rem;
  justify-content: center;
  align-items: center;
  position: sticky;
  bottom: 0;
}

.counter * {
  text-align: center;
}

.counter button {
  background-color: black;
  height: 2rem;
  border-radius: 1rem;
  opacity: 1;
  transition: all 0.2s;
  display: flex;
  justify-content: center;
  align-items: center;
}

.counter button svg {
  width: 40%;
}

.counter button.inactive {
  opacity: 0;
  pointer-events: none;
}

/* stations */

#case-single .station-collection {
  overflow: visible;
  width: 50%;
  position: relative;
  box-sizing: border-box;
  transition: opacity 0.2s;
}

#case-single .station-collection.inactive {
  opacity: 0;
}

#case-single .symbol-collection {
  padding-top: 2rem;
  display: flex;
  flex-direction: row;
  width: 100%;
  justify-content: space-between;
  align-items: center;
  height: 2rem;
}

#case-single .symbol-collection .symbol-single {
  width: 0rem;
  height: 0rem;
  transition: all 0.2s;
  opacity: 0;
  flex-grow: 0;
  transform: translate(50%, 0%);
  text-align: center;
  display: flex;
  justify-content: center;
  align-items: center;
}

#case-single .symbol-single.active {
  width: 1.5rem;
  height: 1.5rem;
  opacity: 1;
  flex-grow: 2;
}

#case-single .symbol-single.active:first-of-type {
  flex-grow: 0;
  margin-left: 0.5rem;
}

#case-single .symbol-single.current {
  width: 4rem;
  height: 4rem;
}

#case-single .symbol-single button {
  transition: transform 0.2s;
  width: 100%;
  height: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
}

#case-single .symbol-single button svg {
  height: 100%;
}

#case-single .symbol-single button.start {
  background-image: none!important;
  background-color: black;
  width: 8px;
  height: 8px;
  border-radius: 11px;
  margin-bottom: -1px;
}

.stop svg,
.barrier svg {
  filter: drop-shadow(0px 0px 10px #FC4C1E);
}

#case-single .line {
  width: 100%;
  box-sizing: border-box;
  padding-left: 2rem;
  position: absolute;
  top: 3rem;
}

#case-single .line hr {
  height: var(--border-width);
}

/* illustrations */

#case-single .illustration {
  display: grid;
  width: 100%;
  height: 100%;
}

.illustration .slide-collection {
  position: relative;
}

.illustration .slide-single {
  position: absolute;
  font-size: 3rem;
  text-align: center;
  width: 100%;
  height: 100%;
  justify-content: center;
  align-items: center;
  display: flex;
  opacity: 0;
  transform: translateY(1rem);
  padding: 1rem;
  box-sizing: border-box;
  pointer-events: none;
}

.illustration .slide-single.active {
  opacity: 1;
  transform: translateY(0px);
  transition: all 0.2s;
  pointer-events: all;
}

.illustration .slide-single img {
  max-width: 75%;
  max-height: 75%;
}

/* case collection */

#case-collection .canvas {
  overflow-x: scroll;
  scrollbar-width: none;
}

#case-collection .canvas::-webkit-scrollbar {
  display: none;
}

.case-collection {
  max-width: 55rem;
  min-width: 45rem;
  margin: auto;
  display: flex;
  flex-direction: column;
  padding: 2rem;
  box-sizing: border-box;
}

.case-collection {
  overflow-y: scroll;
}

.case-collection .case-single {
  display: grid;
  grid-template-columns: 5rem 1fr 5rem;
  margin-bottom: 2rem;
}

.case-collection .symbol-collection {
  display: grid;
  position: relative;
  margin-left: 1rem;
  margin-right: 1rem;
  box-sizing: border-box;
}

.case-collection .symbol-single {
  position: relative;
  background-repeat: no-repeat;
  background-position: center;
  background-size: 50%;
  height: 5rem;
  z-index: 100;
  transition: 0.3s;
}

.case-collection .symbol-single:hover {
  transform: scale(1.1);
  cursor: pointer;
}

.symbol-single .popup {
  position: absolute;
  border-radius: 1rem!important;
  border: var(--border-width) solid black;
  box-shadow: none!important;
  max-width: 30em;
  min-width: 15em;
  min-height: 2em;
  background-color: #000000!important;
  padding: 0.5em;
  box-sizing: border-box;
  color: white!important;
  font-family: 'IBM Plex'!important;
  text-align: center!important;
  font-size: 0.65rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s;
  transform: translateY(calc(-50% - 1em));
  transform-origin: center;
}

.symbol-single:hover .popup {
  opacity: 1;
}

.case-collection .head {
  background-position: center;
  background-repeat: no-repeat;
  background-size: contain;
  transition: 0.3s;
}

.case-collection .head:hover {
  transform: scale(1.1);
}

.case-collection .symbol-single {
  display: flex;
  justify-content: center;
  align-items: center;
}

.case-collection .head svg {
  height: 75%;
}

.case-collection .symbol-collection svg {
  height: 50%;
}

.case-collection .line {
  position: absolute;
  width: 100%;
  top: 50%;
  z-index: 0;
  overflow: visible;
}

.case-collection .line:before {
  display: block;
  position: absolute;
  content: "";
  height: 6px;
  width: 6px;
  top: -3px;
  border-radius: 10px;
  background-color: black;
}

.notification {
  position: absolute;
  left: 0.5rem;
  top: 0.5rem;
  width: 12rem;
  background-color: black;
  font-family: 'IBM Plex';
  color: white;
  font-size: 0.85rem;
  padding: 1.25rem;
  border-radius: 1em;
  line-height: 1.5;
  z-index: 1000;
  text-align: center;
  transition: 0.5s;
}

.notification.hidden {
  transform: translateY(-1rem);
  opacity: 0;
  pointer-events: none;
}

.notification p:not(:last-child) {
  margin-bottom: 1em;
}

/* map */

#map {
  height: 100%;
  background-color: var(--grey);
  width: 100%;
  box-sizing: border-box;
  position: absolute;
  transition: margin 0.5s;
}

#map.focus {
  margin-left: -14rem;
}

.legend {
  position: absolute;
  left: 0.5rem;
  bottom: 0.5rem;
  border-radius: 0.5rem;
  height: auto;
  width: auto;
  padding: 0.5rem!important;
  pointer-events: none;
  z-index: 400;
  background-color: #e2e2e2a4;
  backdrop-filter: blur(10px);
}

.legend svg {
  height: 1.5rem;
  margin-bottom: 0.25rem;
}

.legend ul {
  display: flex;
  flex-direction: row;
  gap: 0.75rem;
}

.legend li {
  display: flex;
  flex-direction: column;
  align-items: center;
  font-weight: 500;
}

.description-collection {
  position: absolute;
  z-index: 1500;
  right: calc(-28em - var(--border-width));
  top: 0;
  height: 100%;
  width: 28rem;
  overflow-y: scroll;
  transition: 0.5s;
  border-left: var(--border-width) solid black;
  background-color: var(--white);
}

.description-collection.active {
  right: 0;
}

.description-single {
  background-color: white;
  box-sizing: border-box;
  border-bottom: var(--border-width) solid black;
}

.description-single:last-child {
  border-bottom: none;
}

.description-single .title {
  padding: calc(0.35em + var(--border-width));
  cursor: pointer;
  min-height: 1em;
  font-size: 1rem;
  font-weight: 500;
  display: flex;
  flex-direction: row;
  align-items: center;
  position: sticky;
  top: 0;
  background-color: white;
  z-index: 100;
}

.description-single.active .title {
  border-bottom: var(--border-width) solid black;
}

.description-single .title svg {
  display: inline-block;
  height: 1.5em;
  width: 1.5em;
  margin-right: 0.5em;
}

.description-single .text {
  display: none;
  padding: calc(0.75 * var(--gap));
}

.description-single.active .text {
  display: block;
}

.description-single .text p:not(:last-child) {
  margin-bottom: 1em;
}

/* leaflet */

.leaflet-popup-content-wrapper {
  border-radius: 1rem!important;
  border: var(--border-width) solid black;
  box-shadow: none!important;
  width: 20em;
  min-height: 2em;
  background-color: #000000!important;
  margin-left: -10rem;
  padding: 1rem;
  color: white!important;
  font-family: 'IBM Plex'!important;
  text-align: center!important;
}

.leaflet-popup-content {
  margin: 0.5em!important;
  margin-right: 1em!important;;
}

.leaflet-popup-tip-container {
  display: none!important;
}

.leaflet-popup-close-button {
  display: none!important;
}

.leaflet-control-attribution {
  display: none!important;
}

/* glossary */

.glossary-marker {
  cursor: pointer;
  background-color: rgb(0, 0, 0);
  border-radius: 1em;
  width: 1.3em;
  height: 1.3em;
  display: inline-block;
  transform: translateY(0.1em);
  color: white;
  font-family: 'IBM Plex';
  text-align: center;
  font-size: 0.77em;
  transform: translateY(-0.1em);
  z-index: 0;
}

#glossary-container {
  display: flex;
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100%;
  box-sizing: border-box;
  background-color: #0000004d;
  z-index: 5000;
  justify-content: center;
  align-items: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s;
}

#glossary-container.active {
  opacity: 1;
  pointer-events: all;
}

.glossary-content {
  width: 25rem;
  max-width: 75vw;
  background-color: black;
  font-family: 'IBM Plex';
  color: white;
  font-size: 0.85rem;
  padding: 1.25rem;
  border-radius: 1em;
  line-height: 1.5;
}

.glossary-title {
  margin-bottom: 1em;
}

.glossary-single {
  margin-bottom: 2rem;
}

.glossary-single h2 {
  font-weight: 500;
}

/* about */

#two-columns {
  width: 100%;
  height: 100%;
  background-color: var(--white);
  box-sizing: border-box;
  display: flex;
}

#two-columns .column {
  width: 50%;
  overflow-y: scroll;
  padding: var(--gap);
  box-sizing: border-box;
  scrollbar-width: none;
}

#two-columns .column::-webkit-scrollbar {
  display: none;
}

.column.left {
  border-right: var(--border-width) solid black;
}

.content {
  font-size: 1.15rem;
}

.content p:not(:last-child) {
  margin-bottom: 1em;
}

.logos {
  display: flex;
  flex-wrap: wrap;
  width: 100%;
  gap: 2rem;
  padding-top: 1rem;
  padding-bottom: 1rem;
}

.logos img {
  max-height: 7rem;
}

/* reader */

.document-collection {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  overflow-y: scroll;
  max-width: 85rem;
  margin: auto;
}

.document-single {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 3rem;
  box-sizing: border-box;
}

.document-single img {
  display: block;
  width: 100%;
  aspect-ratio: 3/4;
  outline: var(--border-width) solid black;
  outline-offset: -1px;
  mix-blend-mode: darken;
}

.document-single .download {
  margin: auto;
  margin-top: 1rem;
  max-width: 10em;
  text-align: center;
  font-family: 'IBM Plex';
  font-size: 0.85rem;
}

/* intro */

#home {
  background-color: #E2E2E2;
  overflow-x: hidden;
}

#home header {
  position: sticky;
  top: 0;
  z-index: 100;
}

#home footer {
  position: fixed;
  bottom: 0;
}

#home h1 {
  visibility: hidden;
}

.intro {
  position: absolute;
  top: 0;
  left: 0;
  bottom: 4rem;
}

.intro svg {
  width: 100%;
  pointer-events: none;
  padding-bottom: 3rem;
  box-sizing: border-box;
}

.intro .mobile {
  display: none;
}

.logo {
  position: absolute;
  top: 0;
  left: 0;
  pointer-events: none;
  transition: 1s;
}

.logo.lazy {
  opacity: 0;
  transform: translateY(2rem);
}

.logo.loaded {
  opacity: 1;
  transform: translateY(0rem);
}

.logo img {
  position: relative;
  top: calc(0.5em + 10vw);
  left: 29vw;
  width: 42vw;
}

.logo h2 {
  position: relative;
  font-size: calc(0.5rem + 1vw);
  line-height: 1.2;
  font-weight: 500;
  width: auto;
  display: inline-block;
}

.de .logo h2,
.de-simple .logo h2 {
  left: -8.85%;
  top: calc(0.1em + 14vw);
}

.en .logo h2 {
  left: -7.5%;
  top: calc(0.5em + 8vw);
}

.pol .logo h2 {
  left: -7.5%;
  top: calc(0.5em + 13.75vw);
}

.tu .logo h2 {
  left: -8%;
  top: calc(0.5em + 13.5vw);
}

.textblocks {
  position: absolute;
  top: 0;
  left: 0;
}

.textblock {
  position: absolute;
  max-width: 32vw;
  font-size: 1.5vw;
  padding-right: 1em;
  box-sizing: border-box;
  background-color: #E2E2E2;
  padding: 0.2em;
  box-sizing: border-box;
  transition: opacity 1s, margin 1s;
}

.textblock.lazy {
  opacity: 0;
  margin-top: 2em;
}

.textblock.loaded {
  opacity: 1;
  margin-top: 0em;
}

.textblock[data-id="1"] {
  left: 40vw;
  top: 110.5vw;
  transform: translateY(-50%);
}

.textblock[data-id="2"] {
  left: 20vw;
  top: 131vw
}

.textblock[data-id="3"] {
  left: 40vw;
  top: 152vw
}

.textblock[data-id="4"] {
  left: 40vw;
  top: 175vw
}

.textblock[data-id="5"] {
  left: 1rem;
  top: 190vw
}

.textblock[data-id="6"] {
  right: 30vw;
  top: 246.5vw;
  text-align: right;
  transform: translateY(-50%)
}

.textblock[data-id="7"] {
  left: 40vw;
  top: 275vw
}

.textblock[data-id="8"] {
  left: 50vw;
  top: 323vw;
  text-align: center;
  transform: translateX(-50%);
}

.textblock[data-id="9"] {
  left: 50vw;
  top: 378vw;
  text-align: center;
  transform: translateX(-50%);
}

.textblock[data-id="10"] {
  left: 30vw;
  top: 439vw;
  transform: translateY(-50%);
}

.textblock[data-id="11"] {
  left: 40vw;
  top: 469vw
}

.textblock[data-id="12"] {
  left: 1rem;
  top: 490vw
}

.textblock[data-id="13"] {
  left: 60vw;
  top: 532vw
}

.textblock[data-id="14"] {
  left: 45vw;
  top: 610vw
}

#home .button {
  position: fixed;
  left: 1rem;
  bottom: 1rem;
  background-color: black;
  color: white;
  font-family: 'IBM Plex';
  padding: 0.5em 2em 0.5em 2em;
  border-radius: 2em;
  z-index: 90;
}
