/* ===== DSGVO Consent Manager ===== */

/* --- Ebene 1: Banner --- */
.zph-cb {
  position: fixed;
  z-index: 99990;
  display: none;
  font-family: "Roboto Condensed", sans-serif;
}
.zph-cb.zph-open { display: block; }

.zph-cb--box {
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
}
.zph-cb--box .zph-cb__inner {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: min(560px, calc(100vw - 32px));
  background: #fff;
  border-radius: 12px;
  padding: 28px 32px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

.zph-cb--bar {
  left: 0;
  right: 0;
  bottom: 0;
}
.zph-cb--bar .zph-cb__inner {
  background: #fff;
  border-top: 3px solid var(--e-global-color-primary, #7C284E);
  box-shadow: 0 -8px 30px rgba(0, 0, 0, 0.15);
  padding: 20px 24px;
  max-width: 1200px;
  margin: 0 auto;
}

.zph-cb__title {
  font-family: "Montserrat", sans-serif;
  font-size: 20px;
  color: var(--e-global-color-primary, #7C284E);
  margin: 0 0 10px;
}
.zph-cb__text {
  color: var(--e-global-color-text, #7A7A7A);
  font-size: 15px;
  margin: 0 0 10px;
}
.zph-cb__links {
  font-size: 13px;
  margin: 0 0 14px;
}
.zph-cb__links a {
  color: var(--e-global-color-secondary, #668AA3);
  text-decoration: underline;
}
.zph-cb__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

.zph-btn {
  font-family: "Montserrat", sans-serif;
  font-size: 14px;
  font-weight: 600;
  border-radius: 6px;
  padding: 10px 18px;
  cursor: pointer;
  border: 2px solid transparent;
  transition: opacity 0.15s ease;
}
.zph-btn:hover { opacity: 0.85; }
.zph-btn--primary {
  background: var(--e-global-color-primary, #7C284E);
  color: #fff;
}
.zph-btn--ghost {
  background: transparent;
  border-color: var(--e-global-color-primary, #7C284E);
  color: var(--e-global-color-primary, #7C284E);
}
.zph-btn--link {
  background: none;
  color: var(--e-global-color-text, #7A7A7A);
  text-decoration: underline;
  padding: 10px 6px;
}

/* --- Ebene 2: Einstellungs-Modal --- */
.zph-cm {
  position: fixed;
  inset: 0;
  z-index: 99991;
  display: none;
  background: rgba(0, 0, 0, 0.55);
  font-family: "Roboto Condensed", sans-serif;
}
.zph-cm.zph-open { display: block; }
.zph-cm__box {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: min(640px, calc(100vw - 32px));
  max-height: min(85vh, 720px);
  overflow-y: auto;
  background: #fff;
  border-radius: 12px;
  padding: 28px 32px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}
.zph-cm__box h2 {
  font-family: "Montserrat", sans-serif;
  font-size: 20px;
  color: var(--e-global-color-primary, #7C284E);
  margin: 0 0 10px;
}
.zph-cm__box > p {
  font-size: 14px;
  color: var(--e-global-color-text, #7A7A7A);
  margin: 0 0 16px;
}
.zph-cm__cat {
  border: 1px solid #e5e5e5;
  border-radius: 8px;
  padding: 14px 16px;
  margin-bottom: 12px;
}
.zph-cm__cathead {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  cursor: pointer;
  color: #444;
  font-size: 15px;
}
.zph-cm__cathead small {
  color: var(--e-global-color-text, #7A7A7A);
}
.zph-cm__svcs {
  margin: 10px 0 0 52px;
  padding: 0;
  list-style: disc;
  font-size: 13px;
  color: var(--e-global-color-text, #7A7A7A);
}
.zph-cm__svcs li { margin-bottom: 4px; }

/* Schalter */
.zph-switch {
  position: relative;
  flex: 0 0 38px;
  height: 22px;
  margin-top: 2px;
}
.zph-switch input {
  position: absolute;
  opacity: 0;
  width: 100%;
  height: 100%;
  margin: 0;
  cursor: pointer;
}
.zph-switch__ui {
  display: block;
  width: 38px;
  height: 22px;
  border-radius: 11px;
  background: #ccc;
  transition: background 0.15s ease;
}
.zph-switch__ui::after {
  content: "";
  position: absolute;
  top: 3px;
  left: 3px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #fff;
  transition: transform 0.15s ease;
}
.zph-switch input:checked + .zph-switch__ui {
  background: var(--e-global-color-accent, #61CE70);
}
.zph-switch input:checked + .zph-switch__ui::after {
  transform: translateX(16px);
}
.zph-switch input:disabled + .zph-switch__ui {
  opacity: 0.6;
}

/* --- Widerrufs-Button --- */
.zph-consent-fab {
  position: fixed;
  left: 16px;
  bottom: 16px;
  z-index: 99980;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: none;
  background: var(--e-global-color-primary, #7C284E);
  color: #fff;
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.25);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.15s ease;
}
.zph-consent-fab:hover { transform: scale(1.08); }
.zph-consent-fab svg { width: 20px; height: 20px; }

/* --- Embed-Platzhalter (2-Klick-Lösung) --- */
.zph-embed-placeholder {
  position: relative;
  background: #f3f4f6;
  border: 1px dashed #c8ccd0;
  border-radius: 8px;
  min-height: 220px;
  display: flex;
  align-items: center;
  justify-content: center;
  aspect-ratio: 16 / 9;
  max-width: 100%;
}
.zph-embed-inner {
  text-align: center;
  padding: 24px;
  max-width: 420px;
}
.zph-embed-inner p {
  font-size: 14px;
  color: var(--e-global-color-text, #7A7A7A);
  margin: 0 0 14px;
}
.zph-embed-load {
  font-family: "Montserrat", sans-serif;
  font-size: 14px;
  font-weight: 600;
  background: var(--e-global-color-primary, #7C284E);
  color: #fff;
  border: none;
  border-radius: 6px;
  padding: 10px 18px;
  cursor: pointer;
}
.zph-embed-load:hover { opacity: 0.85; }
.zph-embed-always {
  display: block;
  margin-top: 10px;
  font-size: 12px;
  color: var(--e-global-color-text, #7A7A7A);
  cursor: pointer;
}

/* --- Mobil --- */
@media (max-width: 600px) {
  .zph-cb--box .zph-cb__inner,
  .zph-cm__box {
    padding: 20px;
  }
  .zph-cb__actions .zph-btn {
    flex: 1 1 100%;
    text-align: center;
  }
}
