/* html {
  font-size: 14px;
} */

/* html * {
  font-family: "montserrat", Arial, Helvetica, sans-serif;
  transition: all 0.3s;
  color: var(--fc);
} */

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* body {
  min-height: 100vh;
  background-color: var(--secondary-color);
  display: flex;
  flex-direction: column;
}

header,
footer {
  background-color: var(--secondary-color);
  box-shadow: var(--shadow);
  z-index: 2;
  position: relative;
} */

main {
  flex: 1;
}

/* header {
  display: flex;
  align-items: center;
  background-color: var(--main-color);
  height: 5rem;
  padding-inline: 10vw;
  border-bottom: 1px solid var(--border-color);
}

header nav ul li {
  list-style: none;
}

footer {
  border-top: 1px solid var(--border-color);
  background-color: var(--main-color);
}

header div:has(img) {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  height: 100%;
}

header div:has(img) img {
  height: 100%;
} */

@media (prefers-color-scheme: dark) {
  .logo {
    filter: invert(1);
  }

  a.card svg {
    filter: invert(1);
  }

  .voteIcon svg {
    filter: invert(1);
  }

  .showMore {
    color: var(--fc);
    text-decoration: underline;
  }
}

/* section {
  padding-inline: 10vw;
} */

/* h1 {
  text-align: center;
} */

details {
  margin-bottom: 1rem;
  background: var(--main-color);
  border-radius: 8px;
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.05);
  padding: 1rem;
  border: 1px solid var(--border-color);
  width: 100%;
}

summary {
  font-weight: bold;
  cursor: pointer;
  /* margin-bottom: 0.5rem; */
}

.day-block {
  background: var(--secondary-color);
  margin: 1rem 0;
  padding: 1rem;
  border-radius: 6px;
  border: 1px solid var(--border-color);
}

.day-title {
  font-size: 1rem;
  font-weight: bold;
  margin-bottom: 0.5rem;
}

.slots {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(60px, 1fr));
  gap: 0.5rem;
}

.slot {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0.5rem 1rem;
  border: 1px solid var(--input-border-color);
  background: var(--input-color);
  border-radius: 6px;
  cursor: pointer;
  transition: 0.2s;
}

.slot:hover {
  border-color: var(--peak-color);
}

.slot.booked {
  border: 2px solid red;
  background: #fdd;
  color: #000;
  pointer-events: none;
  opacity: 0.6;
}

.slot.past {
  opacity: 0.4;
  pointer-events: none;
}

dialog {
  padding: 1.5rem 1rem 1rem 1rem;
  border: none;
  border-radius: 10px;
  box-shadow: 0 0 20px rgba(0, 0, 0, 0.3);
  max-width: 400px;
  width: 90%;
  position: relative;
}

/* label {
  display: block;
  margin-top: 1rem;
} */

input,
textarea {
  width: 100%;
  padding: 0.5rem;
  border: 1px solid var(--input-border-color);
  background: var(--input-color);
  border-radius: 5px;
  box-sizing: border-box;
  font-family: inherit;
  font-size: 1rem;
  line-height: 1.4;
}

textarea {
  height: 100px;
  resize: none;
  overflow-y: auto;
  overflow-x: hidden;
}

/* ✅ Schließen-Button – klein, oben rechts, klare Klickfläche */
/* .close-btn {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 24px;
  height: 24px;
  background: transparent;
  border: none;
  font-size: 1rem;
  color: #666;
  cursor: pointer;
  padding: 0;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
}

.close-btn:hover {
  background: rgba(0, 0, 0, 0.05);
  color: #000;
} */

/* button {
  margin-top: 1rem;
  padding: 0.6rem 1.2rem;
  background: #007BFF;
  color: #fff;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  width: 100%;
} */

/* button,
a.button {
  margin-top: 1rem;
  padding: 0.5rem 0.8rem;
  border-radius: 10rem;
  border: solid 2px var(--peak-color);
  background-color: transparent;
  cursor: pointer;
  width: 100%;
  transition: all 0.3s;
}

button.btnHero,
a.btnHero {
  background-color: var(--peak-color);
  color: var(--fc-white, #fff);
  font-weight: 700;
  font-size: 1rem;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.15);
  cursor: pointer;
}

button:hover {
  transform: scale(1.02);
} */

.response-message {
  text-align: center;
  margin-top: 1rem;
  font-weight: bold;
}

.custom-link {
  display: block;
  margin-top: 1rem;
  font-size: 0.95rem;
  color: #666;
  cursor: pointer;
  text-decoration: underline;
  margin-left: 0.5rem;
}

.custom-link:hover {
  color: #333;
}

.g-recaptcha {
  margin-top: 1rem;
  margin-bottom: 1rem;
}

.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  max-width: none;
  width: 100vw;
  height: 100vh;
  background-color: rgba(0, 0, 0, 0.6);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 1;
  padding-inline: var(--free-space);
}


@media (prefers-color-scheme: dark) {
  .modal-overlay {
    background-color: rgba(255, 255, 255, 0.2);
  }
}

.modal-overlay form {
  background: var(--main-color);
  padding: 0.5rem;
  border-radius: 8px;
  border: 1px solid var(--border-color);
  width: 100%;
  max-width: 500px;
  box-shadow: var(--shadow);
  position: relative;
  max-height: calc(100vh - 12rem);
  
  /* NEU: Flexbox aktivieren */
  display: flex;
  flex-direction: column;
}

.modal-overlay form>div {
  overflow-y: auto;
  overflow-x: visible;
  padding: 0.5rem;
  /* NEU: Nimmt den verfügbaren Platz ein und respektiert die Max-Height des Forms */
  flex-grow: 1; 
}


.modal-overlay .close-btn {
  position: absolute;
  top: 0.5rem;
  right: 0.5rem;
  background: none;
  border: none;
  font-size: 1.2rem;
  cursor: pointer;
}

.g-recaptcha {
  display: flex;
  justify-content: center;
  margin: 1rem 0;
}

#captcha-error {
  color: red;
  text-align: center;
  margin-bottom: 1rem;
}

/* .close-btn {
  position: absolute;
  top: 1rem;
  right: 1rem;
  background: transparent;
  border: none;
  font-size: 1.5rem;
  cursor: pointer;
  color: #333;
} */

#termin-info {
  text-align: center;
  font-weight: bold;
  margin: 1em 0;
}


#form-termin-info {
  margin: 1em 0;
  font-weight: bold;
  text-align: center;
}

.slot.highlight-active {
  border: 1px solid #ffd11a;
  outline: 2px solid #ffd11a;
  outline-offset: 2px;
  color: #000;
  background: #fff9cc;
  pointer-events: auto;
  opacity: 1;
}