/**
 * Cookie-Consent-Banner + Dialog, optisch an campaign-red-mit-uns angelehnt.
 * Nutzt eigene Klassen (cookie-consent / cookie-dialog), keine Kollision mit bestehenden CMS-Klassen.
 */
.cookie-consent {
  position: fixed;
  right: 0;
  bottom: 0;
  left: 0;
  z-index: 20000;
  background: #b51f16 !important;
  color: #fff !important;
  box-shadow: 0 -4px 16px rgba(0, 0, 0, 0.2);
  font-family: inherit;
}

.cookie-consent__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1.5rem;
  max-width: 1440px;
  margin-inline: auto;
  padding: 1rem;
}

.cookie-consent__copy {
  max-width: 850px;
}

.cookie-consent h2,
.cookie-consent p {
  margin: 0;
  color: #fff !important;
}

.cookie-consent h2 {
  font-size: 1.2rem;
}

.cookie-consent a {
  color: #fff !important;
  font-weight: 700;
}

.cookie-consent__actions,
.cookie-dialog__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  align-items: center;
}

.cookie-consent__button {
  min-height: 44px;
  padding: 0.55rem 1rem;
  border: 2px solid #b51f16 !important;
  border-radius: 0 !important;
  background: transparent !important;
  color: #b51f16 !important;
  font: inherit;
  font-weight: 700;
  cursor: pointer;
}

.cookie-consent__button--primary {
  background: #b51f16 !important;
  border-color: #b51f16 !important;
  color: #fff !important;
}

.cookie-consent .cookie-consent__button {
  color: #fff !important;
  border-color: #fff !important;
  background: transparent !important;
}

.cookie-consent .cookie-consent__button--primary {
  background: #000 !important;
  border-color: #000 !important;
  color: #fff !important;
}

/* standards.css shrinks/recolors all button:hover globally - override for cookie banner */
.cookie-consent__button:hover {
  padding: 0.55rem 1rem !important;
  border: 2px solid #b51f16 !important;
  background-color: transparent !important;
  color: #b51f16 !important;
}

.cookie-consent__button--primary:hover {
  background-color: #b51f16 !important;
  color: #fff !important;
}

.cookie-consent .cookie-consent__button:hover {
  border-color: #fff !important;
  background-color: transparent !important;
  color: #fff !important;
}

.cookie-consent .cookie-consent__button--primary:hover {
  background-color: #000 !important;
  border-color: #000 !important;
  color: #fff !important;
}

.cookie-dialog[hidden],
.cookie-consent[hidden] {
  display: none;
}

.cookie-dialog {
  position: fixed;
  inset: 0;
  z-index: 20001;
  display: grid;
  place-items: center;
  padding: 1rem;
}

.cookie-dialog__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
}

.cookie-dialog__panel {
  position: relative;
  max-width: 640px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  background: #fff;
  color: #222;
  padding: 2rem;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
}

.cookie-dialog__panel h2 {
  margin-top: 0;
}

.cookie-dialog__close {
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  background: none;
  border: none;
  font-size: 1.75rem;
  line-height: 1;
  cursor: pointer;
  color: #222;
}

.cookie-dialog__option {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.85rem 0;
  border-bottom: 1px solid #e2e2e2;
}

.cookie-dialog__option h3,
.cookie-dialog__option strong {
  display: block;
  margin: 0 0 0.25rem;
}

.cookie-dialog__option--selectable {
  cursor: pointer;
}

/* standards.css setzt input[type="checkbox"]:not(old) { opacity: 0 } global (Custom-Checkbox-Technik) - hier wieder sichtbar machen */
.cookie-dialog__option input[type="checkbox"] {
  width: 22px;
  height: 22px;
  flex-shrink: 0;
  margin-top: 0.15rem;
  opacity: 1 !important;
}

.cookie-dialog__option input[type="checkbox"]:focus {
  outline: 3px solid #b51f16 !important;
  outline-offset: 2px;
}

/* js/e/standard.js haengt global per $(window).ready() ein .label-Div an jede Checkbox der Seite - hier (nur im Dialog) ausblenden */
.cookie-dialog__option input[type="checkbox"] + .label {
  display: none !important;
}

.cookie-dialog__actions {
  margin-top: 1.5rem;
}

/* Formulare, die ohne Google-Zustimmung (reCAPTCHA) nicht funktionieren */
.form_overlay--consent-required form {
  display: none;
}

.cookie-consent-required-hint {
  background: #fff4f3;
  border: 2px solid #b51f16;
  padding: 1.25rem;
  margin-bottom: 1.5rem;
}

.cookie-consent-required-hint p {
  margin: 0 0 1rem;
}
