body {
  font-family: sans-serif;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 40px;
  margin: 0;
  padding: 0;
  height: 100vh;
  background-image: url("images/tischiii.jpg");
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  background-attachment: fixed; /* optional: für Parallax-Effekt */
}
#menu{
  position: absolute;
  width:100%;
  background-color: #000;
  top: 0px;
  left:0px;
}
.nav {
  display: flex;
  justify-content: space-between;
  width: 80%;
  background: #000;
}

.nav a {
  text-decoration: none;
  color: #fff;
  font-family: "Castoro Titling", serif;
  font-weight: 400;
  font-style: normal;
  padding-top: 20px;
}
#kartenfeld {
  padding-top:30px;
  display: grid;
  grid-template-columns:
    120px 120px 120px 60px   /* Abstand */
    120px 120px 120px 120px
    60px              /* Abstand */
    120px 120px 120px
    60px              /* Abstand */
    120px;
  grid-template-rows: repeat(3, 120px);
  gap: 5px;
}
#stapel {
  position: relative;
  display: grid;
  padding-top:20px;
  grid-template-columns:
    120px 120px 120px 120px   /* Abstand */
    120px 120px 120px 120px
    120px              /* Abstand */
    120px 120px 120px;
       /* Abstand */
  grid-template-rows: repeat(1, 120px);
  gap: 10px;
}
#spielfeld {
  position: relative;
  display: flex;
  flex-direction: column; /* macht die Kinder vertikal statt horizontal */
  justify-content: center;
  align-items: flex-start; /* optional */
}
#hinweis{
  position: absolute;
  padding-left: 0px;
  padding-top:0px;
  font-family: "Cormorant Unicase", serif;
  font-weight: 400;
  font-style: normal;
  font-size: 24px;
  color:white;
  text-align: center;
  z-index:400;
}

#spielstart{
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 40px; /* Abstand zwischen den Elementen */
  font-size: 24px;
  font-weight: bold;
  font-family: "Castoro Titling", serif;
  font-weight: 400;
  font-style: normal;
}
button:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  pointer-events: none; /* wichtig, damit kein Klick durchkommt */
  background-color: #aaaaaa;
}
.button-wrapper {
  display: flex;
  justify-content: center;
  align-items: center;
  margin: 20px 0;
}
.runder-button {
  padding: 12px 24px;
  font-size: 16px;
  background-color: #a21658; /* schönes Grün */
  color: white;
  border: none;
  border-radius: 20px; /* maximal abgerundet */
  cursor: pointer;
  transition: background-color 0.3s ease;
}

.runder-button:hover {
  background-color: #45a049;
}

.karte {
  width: 120px;
  height: 120px;
  background-color: transparent;
  background: transparent;
  /*border: 2px solid #444;*/
  border-radius: 15px;
  display: flex;
  justify-content: center;
  align-items: center;
  font-weight: bold;
  font-size: 18px;
  /*box-shadow: 2px 2px 6px rgba(0, 0, 0, 0.2);*/
  user-select: none;
  transition: transform 0.15s ease;
}
.stapelkarte {
  position:absolute;
  width: 120px;
  height: 120px;
  background-color: transparent;
  background: transparent;
  /*border: 2px solid #444;*/
  border-radius: 15px;
  display: flex;
  justify-content: center;
  align-items: center;
  font-weight: bold;
  font-size: 18px;
  cursor: grab;
  /*box-shadow: 2px 2px 6px rgba(0, 0, 0, 0.2);*/
  user-select: none;
  transition: transform 0.15s ease;
}
.dropfeld {
  border: 4px dashed #aaa;
}
.kclicked {
  border: 2px solid #ffffff;
  box-shadow: 2px 2px 6px rgba(0, 0, 0, 0.2);
}
.karte img {
  width: 100%;
  height: 100%;
  object-fit: cover; /* oder 'contain', je nach Wunsch */
  border-radius: 10px; /* optional, falls du abgerundete Karten willst */
  pointer-events: none; /* verhindert, dass das Bild Klicks abfängt */
}

.abstand {
  background: transparent;
  border: none;
  box-shadow: none;
}

.floating-text {
  position: absolute;
  color: yellow;
  font-size: 20px;
  font-weight: bold;
  pointer-events: none;
  animation: floatUp 1s ease-out forwards;
}

@keyframes floatUp {
  0% {
    opacity: 1;
    transform: translateY(0);
  }
  100% {
    opacity: 0;
    transform: translateY(-40px);
  }
}

.phase-text {
  position: absolute;
  color: white;
  font-size: 120px;
  font-weight: bold;
  font-family: "Castoro Titling", serif;
  font-weight: 400;
  font-style: normal;
  pointer-events: none;
  animation: floatUp 3s ease-out forwards;
}
.card-stack {
  position: relative;
  width: 200px;
  height: 300px;
}



/* Versatz: jede Karte leicht nach unten verschieben */
.card:nth-child(1) {
  top: 0px;
  z-index: 3;
}
.card:nth-child(2) {
  top: 10px;
  z-index: 2;
}
.card:nth-child(3) {
  top: 20px;
  z-index: 1;
}

.sidebar {
  position: fixed;         /* bleibt immer am rechten Rand */
  top: 50%;                /* vertikal mittig */
  right: 0;                /* am rechten Rand */
  transform: translateY(-50%);
  background-color: #222;
  color: white;
  padding: 10px;
  border-radius: 10px 0 0 10px; /* abgerundete linke Ecke */
  display: flex;
  flex-direction: column;
  gap: 10px;
  box-shadow: -2px 2px 8px rgba(0, 0, 0, 0.3);
  z-index: 1000;
}

.sidebar div {
  background-color: #444;
  padding: 8px 12px;
  border-radius: 5px;
  text-align: center;
  font-size: 16px;
}

.sch{
  color: #797979;
}

#timer {
  position: fixed;
  bottom: 20px;
  right: 20px;
  background-color: black;
  color: white;
  font-size: 24px;
  padding: 10px 16px;
  border-radius: 10px;
  font-family: monospace;
  z-index: 1000;
}
#spielstein {
  position: absolute;
  top: 0;
  left: 0;
  cursor: grab;
  display: flex;
  align-items: center;
  justify-content: center;
  user-select: none;
  z-index: 10; /* über Karte sichtbar */
}
