/* =========================================================================
   Consent Manager – Dom Museum Wien
   Zweistufiges Consent-Popup (essenziell / Marketing) + Widerruf
   ========================================================================= */

#dm_consent,
#dm_consent * { box-sizing: border-box; }

/* ---- Banner (Erstbesuch) ---- */
#dm_consent_banner {
  position: fixed;
  bottom: 16px;
  left: 16px;
  right: 16px;
  max-width: 460px;
  margin: 0 auto 0 0;
  background: #ffffff;
  color: #1a1a1a;
  padding: 22px 22px 18px;
  z-index: 1000001;
  box-shadow: 0 6px 30px rgba(0, 0, 0, 0.22);
  border-radius: 6px;
  font-family: 'Heebo', 'Helvetica Neue', sans-serif;
}
#dm_consent_banner .dm_consent_title {
  font-size: 17px;
  font-weight: 700;
  margin: 0 0 8px;
}
#dm_consent_banner .dm_consent_text {
  font-size: 14px;
  line-height: 1.5;
  margin: 0 0 16px;
}
#dm_consent_banner .dm_consent_text a { text-decoration: underline; }

.dm_consent_actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.dm_consent_btn {
  font-family: inherit;
  font-size: 13px;
  line-height: 1.2;
  padding: 10px 16px;
  cursor: pointer;
  border: 1px solid #369de1;
  border-radius: 3px;
  outline: none;
  background: #ffffff;
  color: #369de1;
  flex: 1 1 auto;
}
.dm_consent_btn.dm_consent_btn_primary {
  background: #369de1;
  color: #ffffff;
}
.dm_consent_btn:focus-visible { outline: 2px solid #1a1a1a; outline-offset: 2px; }
.dm_consent_link {
  background: none;
  border: none;
  color: #1a1a1a;
  text-decoration: underline;
  font-family: inherit;
  font-size: 13px;
  cursor: pointer;
  padding: 10px 4px;
  flex: 1 1 100%;
  text-align: center;
}

/* ---- Einstellungen (Modal) ---- */
#dm_consent_modal {
  position: fixed;
  inset: 0;
  z-index: 1000002;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  background: rgba(0, 0, 0, 0.5);
}
#dm_consent_modal .dm_consent_dialog {
  background: #ffffff;
  color: #1a1a1a;
  width: 100%;
  max-width: 540px;
  max-height: 90vh;
  overflow-y: auto;
  border-radius: 6px;
  padding: 26px;
  font-family: 'Heebo', 'Helvetica Neue', sans-serif;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
}
.dm_consent_dialog h2 { font-size: 20px; font-weight: 700; margin: 0 0 6px; }
.dm_consent_dialog .dm_consent_text { font-size: 14px; line-height: 1.5; margin: 0 0 18px; }
.dm_consent_dialog .dm_consent_text a { text-decoration: underline; }

.dm_consent_cat {
  border: 1px solid #e2e2e2;
  border-radius: 5px;
  padding: 14px 16px;
  margin-bottom: 12px;
}
.dm_consent_cat_head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.dm_consent_cat_head .dm_consent_cat_name { font-size: 15px; font-weight: 700; }
.dm_consent_cat_desc { font-size: 13px; line-height: 1.45; margin: 8px 0 0; color: #444; }
.dm_consent_always { font-size: 12px; font-weight: 700; color: #369de1; text-transform: uppercase; letter-spacing: .04em; }

/* Toggle switch */
.dm_switch { position: relative; display: inline-block; width: 44px; height: 24px; flex: 0 0 auto; }
.dm_switch input { opacity: 0; width: 0; height: 0; }
.dm_switch .dm_slider {
  position: absolute; cursor: pointer; inset: 0;
  background: #cfcfcf; border-radius: 24px; transition: .2s;
}
.dm_switch .dm_slider:before {
  content: ""; position: absolute; height: 18px; width: 18px; left: 3px; bottom: 3px;
  background: #fff; border-radius: 50%; transition: .2s;
}
.dm_switch input:checked + .dm_slider { background: #369de1; }
.dm_switch input:checked + .dm_slider:before { transform: translateX(20px); }
.dm_switch input:disabled + .dm_slider { background: #369de1; opacity: .5; cursor: not-allowed; }
.dm_switch input:focus-visible + .dm_slider { outline: 2px solid #1a1a1a; outline-offset: 2px; }

.dm_consent_dialog .dm_consent_actions { margin-top: 20px; }

/* Widerruf/Einstellungen: Aufruf über den Footer-Link (DMConsent.open()). */

[hidden] { display: none !important; }

@media (max-width: 520px) {
  #dm_consent_banner { max-width: none; }
  .dm_consent_btn { flex: 1 1 100%; }
}

/* ---- Bookingkit Zwei-Klick-Platzhalter ---- */
#dm_bk_placeholder {
  position: fixed;
  bottom: 20px;
  right: 20px;
  z-index: 999998;
  max-width: 260px;
}
#dm_bk_load {
  display: block;
  width: 100%;
  text-align: left;
  cursor: pointer;
  font-family: 'Heebo', 'Helvetica Neue', sans-serif;
  background: #369de1;
  color: #ffffff;
  border: none;
  border-radius: 6px;
  padding: 14px 16px;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.22);
}
#dm_bk_load:hover { background: #2b86c4; }
#dm_bk_load:focus-visible { outline: 2px solid #1a1a1a; outline-offset: 2px; }
#dm_bk_load .dm_bk_title {
  display: block;
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 4px;
}
#dm_bk_load .dm_bk_note {
  display: block;
  font-size: 11px;
  line-height: 1.4;
  opacity: 0.95;
}

@media (max-width: 520px) {
  #dm_bk_placeholder { right: 12px; bottom: 12px; max-width: calc(100% - 24px); }
}
