/* ========================================== */
/* GRUND-RESET                                */
/* ========================================== */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

/* Verhindert Scrollen und Zoomen */
html, body {
  width: 100%;
  height: 100%;
  overflow: hidden;
  touch-action: manipulation;
  -ms-touch-action: manipulation;
  -webkit-text-size-adjust: 100%; /* iOS: keine Schriftvergrößerung */
}

/* ========================================== */
/* HINTERGRUND UND BASIS-STYLING              */
/* ========================================== */

/* Hintergrundbild */
body {
  background: url('hintergrund.jpg') no-repeat center center fixed; /* ggf. Pfad anpassen */
  background-size: cover;
  font-family: Arial, sans-serif;
  color: #000;
  position: relative;
}

/* ========================================== */
/* FIXE BUTTONS OBEN (Neues Spiel, Regeln)    */
/* ========================================== */
.top-btn {
  position: fixed;
  top: 20px;
  width: 100px;
  height: 30px;
  background-color: gold;
  color: #000;
  border: none;
  border-radius: 10px;
  font-size: 16px;
  cursor: pointer;
  z-index: 1000;
}
.left-btn.top-btn {
  left: 20px;
}
.right-btn.top-btn {
  right: 20px;
}

/* ========================================== */
/* TITEL IN DER MITTE OBEN                    */
/* ========================================== */
#gameTitle {
  position: fixed;
  top: 20px;
  left: 50%;
  transform: translateX(-50%);
  font-size: 24px;
  font-weight: bold;
  color: gold;
  line-height: 0.5;
  z-index: 1000;
}

/* ========================================== */
/* RUNDENZÄHLER (UNTEN MITTE)                 */
/* ========================================== */
#roundCounter {
  position: fixed;
  bottom: 10px;
  left: 50%;
  transform: translateX(-50%);
  width: 80px;
  background-color: rgba(255, 255, 255, 0.6);
  text-align: center;
  font-size: 20px;
  border-radius: 10px;
  align-items: center;
  height: 50px;
  z-index: 1000;
}

/* ========================================== */
/* SUCHBEREICH (OBEN DRUNTER)                 */
/* ========================================== */
#searchContainer {
  position: fixed;
  top: 120px;
  left: 20px;
  right: 20px;
  display: flex;
  align-items: center;
  height: 50px;
  z-index: 1000;
}

#searchPhrase {
  flex: 1;
  height: 50px;
  background-color: rgba(255, 255, 255, 0.6);
  font-size: 18px;
  padding: 10px;
  border-radius: 10px 0 0 10px;
  display: flex;
  align-items: center;
}

#searchBtnMain {
  height: 50px;
  width: 100px;
  background-color: gold;
  color: #000;
  border: none;
  border-radius: 0 10px 10px 0;
  font-size: 18px;
  cursor: pointer;
}

/* ========================================== */
/* AUTOCOMPLETE-ERGEBNISSE (SCROLLBAR)        */
/* ========================================== */
#autocompleteResults {
  position: fixed;
  top: 180px;
  left: 20px;
  right: 20px;
  max-height: calc(100% - 250px);
  overflow-y: auto;
  z-index: 1000;
}

.autocomplete-item {
  display: flex;
  align-items: center;
  background-color: rgba(255, 215, 0, 0.75);
  padding: 4px;
  margin-bottom: 10px;
  border-radius: 10px;
  font-size: 14px; /* 10% kleiner als 16px */
  height: auto;
}

/* ========================================== */
/* BOTTOM-BEREICH (Überspringen, Nächste)     */
/* ========================================== */
.bottom-btn {
  position: fixed;
  bottom: 20px;
  width: 130px;
  height: 30px;
  background-color: gold;
  color: #000;
  border: none;
  border-radius: 10px;
  font-size: 16px;
  cursor: pointer;
  z-index: 1000;
}
.left-btn.bottom-btn {
  left: 20px;
}
.right-btn.bottom-btn {
  right: 20px;
}

/* ========================================== */
/* NEUES REGELN-OVERLAY IM STIL DEINES BEISPIELS */
/* ========================================== */

/* Unsichtbar, solange .hidden vorhanden ist */
.hidden {
  display: none;
}

/* Modal: dunkler Overlay-Hintergrund */
.modal {
  display: none; /* Standardmäßig unsichtbar */
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.8);
  justify-content: center;
  align-items: center;
  z-index: 2000; /* über allen normalen Inhalten, aber unter 3000+ falls nötig */
  overflow: auto;
  -webkit-overflow-scrolling: touch;
}

/* Innenbereich des Modals */
.modal-content {
  background: #333;
  padding: 20px;
  border-radius: 10px;
  text-align: center; 
  max-width: 90%;
  margin: 40px auto;
  color: #fff; /* Standard-Schriftfarbe weiß */
  position: relative;
}

/* Scrollbare Regel-Inhalte linksbündig, goldene Überschriften */
.rulesContentContainer .rulesContent {
  text-align: left;
  max-height: 70vh; /* Damit es scrollbar bleibt */
  overflow-y: auto;
}

/* Goldene Überschriften innerhalb der Rules */
.rulesContent h2,
.rulesContent h3,
.rulesContent h4 {
  color: gold;
}

/* Buttons im Modal: alle in einer Zeile mit etwas Abstand */
.rulesButtons {
  margin-top: 20px;
  display: flex;
  justify-content: center;
  gap: 10px;
}

/* Einheitlicher Buttonstil im Modal */
.rulesButtons button {
  width: 120px;
  background: gold;
  color: black;
  border: none;
  padding: 10px;
  margin: 0;
  border-radius: 5px;
  cursor: pointer;
  font-weight: bold;
  transition: background 0.3s;
}

.rulesButtons button:hover {
  background: darkgoldenrod;
}

/* ========================================== */
/* VERHINDERT ZOOMEN AUF ALLEN ELEMENTEN      */
/* ========================================== */
html {
  -ms-touch-action: none;
  touch-action: none;
}
