body {
  margin: 0;
  background-color: #ffffff;
  display: flex; /* Flexbox für den gesamten Body */
  flex-direction: column; /* Vertikale Anordnung */
  align-items: center; /* Zentriert den Inhalt horizontal */
}

@font-face {
  font-family: "FT88";
  src: url("fonts/FT88-Regular.woff");
}

h1 {
  margin: 0;
  top: 10px;
  color: #ff69b4;
  font-family: "FT88";
  font-size: 35px;
  cursor: default;
  position: fixed;
  /* Zusatzinfo, Extrawurst damit die in der Mitte ist */
  left: 50%;
  transform: translateX(-50%);
  z-index: 2;
}

#actions {
  position: fixed;
  border: none;
  bottom: 0; /* Abstand von oben */
  left: 0; /* Abstand von links */
  right: 0;
  z-index: 4; /* Im Vordergrund bleiben */
  background-color: transparent;
  display: flex;
  justify-content: center; /* Zentriert die Palette horizontal */
  align-items: baseline;
  background: rgb(255, 255, 255);
  margin: 0 auto;
  max-width: 100%;
  width: max-content;
  flex-wrap: wrap;
}

#actions button,
#actions select,
#actions input,
#actions .file-upload-button {
  font-family: "Helvetica";
  font-size: 13px;
  background-color: transparent; /* Black background for buttons */
  color: #000000; /* White text for contrast */
  border: none; /* Removes default borders */
  padding: 10px 15px; /* Adds padding to buttons */
  cursor: pointer; /* Changes cursor to pointer on hover */
  flex-shrink: 0; /* Prevents buttons from shrinking */
}

/* Hides the default file input */
.file-upload-input {
  display: none;
}

#colorPicker {
  padding-top: 10px;
  transform: translateY(1px);
}
.credits-button {
  left: 20px;
  top: 20px;
  position: fixed;
  font-family: "FT88";
  font-size: 18px;
  background-color: transparent;
  color: #000000;
  border: none;
  cursor: pointer;
  color: #ff69b4;
  z-index: 2;
}

.info-button {
  right: 20px;
  top: 20px;
  position: fixed;
  font-family: "FT88";
  font-size: 15px;
  background-color: transparent;
  color: #000000;
  border: none;
  cursor: pointer;
  color: #ff69b4;
  z-index: 9999;
}

.creditspopup {
  transform: translate(-50%, -50%); /* Centers the popup */
  top: 20%;
  left: 25%;
  position: fixed;
  font-family: "FT88";
  text-align: center;
  font-size: 12px;
  background-color: #ffffff;
  padding: 9px;
  border: #000000 solid 1px;
  z-index: 9999;
}

.creditspopup {
  display: none; /* overlay hidden when open the site */
}

#popup {
  display: none; /* overlay hidden when open the site */
}

.popup {
  transform: translate(-50%, -50%); /* Centers the popup */
  top: 50%;
  left: 50%;
  position: fixed;
  font-family: "FT88";
  text-align: center;
  font-size: 20px;
  background-color: #ffffff;
  padding: 20px;
  border: #000000 solid 1px;
  z-index: 9999;
}

a {
  text-decoration: none; /* Entfernt die Unterstreichung */
  color: blue;
}

#imagePopup {
  position: fixed;
  display: none; /* overlay hidden when open the site */
  z-index: 9999;
  pointer-events: none;
}

#imagePopup img {
  transform: translate(-50%, -50%); /* Centers the popup */
  top: 45%;
  left: 25%;
  position: fixed;
  max-height: 70vh;
  display: block; /* Zeige das Bild */
  z-index: 9998;
}

/* BOOK */
.book {
  display: none; /* overlay hidden when open the site */
  position: fixed;
  width: 46.666vh;
  height: 60vh;
  top: 30%;
  left: 70%;
  transform: translateX(-50%);
  z-index: 9999;
}

.flip-book {
  width: 100%;
  height: 100%;
  position: relative;
  perspective: 1500px;
  /* margin-left: 50vw; */
  /* mix-blend-mode: multiply; */
}

.page {
  width: 100%;
  height: 100%;
  position: absolute;
  top: 0;
  left: 0;
  transform-origin: left;
  transform-style: preserve-3d;
  transform: rotateY(0deg);
  transition: 0.5s;
}

.book .flip-book .page .front img,
.book .flip-book .page .back img {
  width: 100%;
  height: 100%;
  object-fit: contain; /* Bilder werden gezwungen sich anzupassen endlich */
}

.front,
.back {
  position: absolute;
  width: 100%;
  top: 0;
  left: 0;
  box-sizing: border-box;
  opacity: 1;
  /* border: 1px solid grey; */
}

.back {
  z-index: 99;
  transform: rotateY(180deg);
  backface-visibility: hidden;
  @media screen and (max-width: 600px) {
    transform: rotateY(0);
  }
}

.front {
  border-left: 0px solid rgb(0, 0, 0);
}

.page.active .back {
  backface-visibility: visible;
  opacity: 0;
}
.page.active .back.show {
  backface-visibility: visible;
  opacity: 1;
}

.flipped {
  transform: rotateY(-180deg);
  @media screen and (max-width: 600px) {
    transform: rotateY(0);
  }
}

.next,
.prev {
  position: absolute;
  width: 100%;
  height: 100%;
  top: 0;
  left: 0;
  z-index: 9000;
}

.prev {
  left: -21vw;
}

.next:hover {
  cursor: e-resize;
}

.prev:hover {
  cursor: w-resize;
}
/* BOOK ENDE */

/* ----- GRID CONTAINER ----- */
.grid-container {
  position: relative;
  top: 95px;
  /* flex-direction: column; */
  align-items: center; /* Zentriert die Kästchen-Zeilen horizontal */
  gap: 0px;
  border: #000000 solid 1mm;
  background-color: #ffffff;
  transform-origin: top center; /* Setzt den Ursprung der Skalierung */
  /* width: max-content;
  height: max-content; */
  z-index: 3;
}

/*  Kästchen */
.grid-item {
  width: 5mm; /* Breite eines Kästchens */
  height: 5mm; /* Höhe eines Kästchens  */
  background-color: rgb(255, 255, 255);
  border: 0.01px solid #000000;
  cursor: crosshair;
  box-sizing: border-box;
}

.row,
.col {
  display: flex; /* Flexbox für die Zeilen */
  justify-content: center; /* Center grid items horizontally */
  align-items: center; /* Center items vertically */
  margin: 0 auto; /* Center the row itself */
}
/* ----- GRID CONTAINER ENDE ----- */
