/* style.css */

/* Hintergrundbild & Grundlayout */
body {
  margin: 0;
  padding: 0;
  background: url("HintergrundBlauGold.jpg") no-repeat center center fixed;
  background-size: cover;
  color: white;
  font-family: Arial, sans-serif;
  min-height: 100vh;
  overflow: hidden;
    touch-action: none;         /* <--- Ergänzen */
  -ms-touch-action: none;     /* <--- Ergänzen */
}

/* Titel oben in der Mitte */
#gameTitle {
  position: absolute;
  top: 10px;
  left: 50%;
  transform: translateX(-50%);
  text-align: center;
  color: gold;
  z-index: 10; /* Stellt sicher, dass es immer sichtbar bleibt */

  /* Neue Eigenschaften hinzufügen */
  max-width: calc(100% - 60px); /* 80px reservieren für die Buttons (40px pro Seite) */
  padding: 0 30px; /* Innenabstand auf beiden Seiten */
  box-sizing: border-box; /* Sicherstellen, dass Padding zur Breite zählt */
}

.mainTitle {
  font-size: clamp(1.275rem, 4.25vw, 1.7rem); /* 15% kleiner als vorher */
  font-weight: bold;
  margin-bottom: 0.2em;
}

.subTitle {
  font-size: clamp(1rem, 4vw, 1.5rem);
  margin: 0;
}

/* Buttons in den Ecken */
.top-left-buttons {
  position: absolute;
  top: 10px;
  left: 10px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  z-index: 1000;
}

.btn-top-left, .btn-top-right, .btn-bottom-right {
  background-color: gold;
  color: black;
  border: none;
  padding: 10px 15px;
  border-radius: 10px;
  font-weight: bold;
  cursor: pointer;
  box-shadow: 2px 2px 5px rgba(0, 0, 0, 0.5);
  transition: background-color 0.3s;
}

.btn-top-left:hover, .btn-top-right:hover, .btn-bottom-right:hover {
  background-color: #e0b800;
}

.btn-top-right {
  position: absolute;
  top: 10px;
  right: 10px;
}

.btn-bottom-right {
  position: absolute;
  bottom: 10px;
  right: 10px;
}

/* Hauptbereich für Frage und Hinweise */
#mainContent {
  width: 90%;
  margin: auto;
  margin-top: 150px; /* Platz fürs Titel-Overlay */
  text-align: center;
  position: relative; /* Hinzugefügt */
  top: -30px; /* Verschiebt den Container etwas nach oben */
  box-sizing: border-box;
}

/* Die Frage selbst (grauer, halbtransparenter Hintergrund) */
#questionText {
  display: inline-block;
  background-color: rgba(128, 128, 128, 0.8);
  border-radius: 10px;
  box-shadow: 2px 2px 5px rgba(0, 0, 0, 0.5);
  padding: 15px 20px;
  margin: 15px auto;
  text-align: center;
  font-size: clamp(1.2rem, 4vw, 1.5rem);
  position: relative;
  z-index: 5;
  box-sizing: border-box;
}

/* Container für Hinweise & Lösung */
#hintContainers {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 15px;
  box-sizing: border-box;
}

.hintContainer {
  width: 100%;
  max-width: 100%;
  position: relative;
  box-sizing: border-box;
}

.hintButton {
  width: 100%;
  background-color: gold;
  color: black;
  border: none;
  border-radius: 10px;
  box-shadow: 2px 2px 5px rgba(0, 0, 0, 0.5);
  padding: 10px 15px;
  cursor: pointer;
  font-weight: bold;
  transition: background-color 0.3s;
  box-sizing: border-box;
}

.hintButton:hover {
  background-color: #e0b800;
  box-sizing: border-box;
}

.hint, .answer {
  width: 100%;
  background-color: rgba(128, 128, 128, 0.8);
  border-radius: 10px;
  box-shadow: 2px 2px 5px rgba(0, 0, 0, 0.5);
  padding: 15px 20px;
  text-align: center;
  display: none; /* Wird per JS eingeblendet */
  margin-top: 10px;
  font-size: 1rem;
  box-sizing: border-box;
}

/* Blinds unten links */
#blindsArea {
  position: absolute;
  bottom: 10px;
  left: 10px;
  background-color: rgba(0, 0, 0, 0.6);
  padding: 10px 15px;
  border-radius: 10px;
  box-shadow: 2px 2px 5px rgba(0, 0, 0, 0.5);
}

#blindsArea div {
  margin-bottom: 5px;
  font-weight: bold;
}

/* Overlay für Regeln */
#rulesOverlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.7);
  z-index: 2000;
  display: none;
  justify-content: center;
  align-items: center;
}

#rulesContent {
  width: 90%;
  max-width: 700px;
  max-height: 70vh;
  overflow-y: auto;
  background-color: rgba(0, 0, 0, 0.8);
  color: white;
  padding: 20px 25px;
  border-radius: 10px;
  text-align: left;
  box-shadow: 2px 2px 10px rgba(0, 0, 0, 0.7);
}

#rulesContent h2, #rulesContent h3 {
  color: gold;
}

#rulesContent button {
  background-color: gold;
  color: black;
  border: none;
  border-radius: 10px;
  padding: 10px 20px;
  cursor: pointer;
  margin-top: 20px;
  transition: background-color 0.3s;
}

#rulesContent button:hover {
  background-color: #e0b800;
}

/* --- NEU: Container für die drei Buttons (Schließen, Feedback, Spenden) nebeneinander --- */
.rulesButtons {
  display: flex;
  gap: 10px;
  justify-content: center; /* oder 'flex-start', falls linksbündig gewünscht */
  margin-top: 20px; /* Abstand zum Inhalt oben */
}

/* Responsive Design */
@media (max-width: 768px) {
  #gameTitle {
    font-size: 1.35rem; /* 10% kleiner für mobile Ansicht */
  }
  .mainTitle {
    font-size: 1.62rem;
  }
  .subTitle {
    font-size: 1rem;
  }
  #mainContent {
    width: 80%; /* Erhöhung der Breite */
    margin-top: 195px; /* Stack minimal nach unten verschoben */
  }
  #questionText {
    font-size: 1rem; /* Rückgängig auf Standardgröße */
    padding: 12px; /* Rückgängig auf Standardgröße */
  }
  .hintButton {
    font-size: 0.8rem; /* Rückgängig auf Standardgröße */
  }
  .hint, .answer {
    font-size: 0.9rem; /* Rückgängig auf Standardgröße */
    padding: 12px; /* Rückgängig auf Standardgröße */
  }
  #blindsArea {
    font-size: 0.85rem; /* Rückgängig auf Standardgröße */
    padding: 8px 12px; /* Rückgängig auf Standardgröße */
    transform: scale(0.85); /* 15% Verkleinerung der Blinds */
  }
  .top-left-buttons {
    flex-direction: column; /* Buttons untereinander anordnen */
  }
}
