#ab-privacy-banner,
#ab-privacy-modal {
  --privacy-bg: #0c1522;
  --privacy-panel: #ffffff;
  --privacy-text: #152231;
  --privacy-muted: #526274;
  --privacy-border: #d8e0e8;
  --privacy-accent: #e65e22;
  --privacy-focus: #ffbf47;
  font-family: inherit;
}

.ab-privacy-banner {
  position: fixed;
  z-index: 2147483000;
  left: 16px;
  right: 16px;
  bottom: 16px;
  max-width: 980px;
  margin: 0 auto;
  background: var(--privacy-panel);
  color: var(--privacy-text);
  border: 1px solid var(--privacy-border);
  border-radius: 16px;
  box-shadow: 0 18px 60px rgba(0, 0, 0, .28);
}

.ab-privacy-banner[hidden],
.ab-privacy-modal[hidden] {
  display: none !important;
}

.ab-privacy-banner-inner {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 20px;
  align-items: center;
  padding: 20px;
}

.ab-privacy-banner h2,
.ab-privacy-modal h2,
.ab-privacy-modal h3 {
  margin-top: 0;
}

.ab-privacy-banner h2 {
  margin-bottom: 7px;
  font-size: 1.15rem;
}

.ab-privacy-banner p {
  margin: 0;
  max-width: 760px;
  color: var(--privacy-muted);
  line-height: 1.55;
}

.ab-privacy-banner a,
.ab-privacy-modal a {
  color: inherit;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.ab-privacy-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

.ab-privacy-button {
  appearance: none;
  border: 1px solid #1b2a3a;
  border-radius: 10px;
  padding: 10px 14px;
  min-height: 44px;
  background: #fff;
  color: #152231;
  font: inherit;
  font-weight: 700;
  cursor: pointer;
}

.ab-privacy-button.primary,
.ab-privacy-button.reject {
  background: #152231;
  color: #fff;
}

.ab-privacy-button:hover {
  filter: brightness(.96);
}

.ab-privacy-button:focus-visible,
.ab-privacy-toggle input:focus-visible + span,
[data-open-privacy-settings]:focus-visible {
  outline: 3px solid var(--privacy-focus);
  outline-offset: 3px;
}

.ab-privacy-modal {
  position: fixed;
  z-index: 2147483100;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 20px;
}

.ab-privacy-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(5, 12, 20, .72);
}

.ab-privacy-dialog {
  position: relative;
  z-index: 1;
  width: min(760px, 100%);
  max-height: min(820px, calc(100vh - 40px));
  overflow: auto;
  background: var(--privacy-panel);
  color: var(--privacy-text);
  border-radius: 16px;
  box-shadow: 0 22px 80px rgba(0, 0, 0, .38);
}

.ab-privacy-dialog-header,
.ab-privacy-dialog-body,
.ab-privacy-dialog-footer {
  padding: 22px 24px;
}

.ab-privacy-dialog-header {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: flex-start;
  border-bottom: 1px solid var(--privacy-border);
}

.ab-privacy-dialog-header h2 {
  margin-bottom: 7px;
}

.ab-privacy-dialog-header p,
.ab-privacy-summary,
.ab-privacy-category p,
.ab-privacy-status {
  color: var(--privacy-muted);
  line-height: 1.55;
}

.ab-privacy-close {
  appearance: none;
  border: 1px solid var(--privacy-border);
  background: #fff;
  color: #152231;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  cursor: pointer;
  flex: 0 0 auto;
  font-size: 1.3rem;
}

.ab-privacy-status {
  padding: 12px 14px;
  margin: 0 0 18px;
  border-radius: 10px;
  background: #f3f6f9;
}

.ab-privacy-category {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 18px;
  align-items: start;
  padding: 18px 0;
  border-top: 1px solid var(--privacy-border);
}

.ab-privacy-category:first-of-type {
  border-top: 0;
}

.ab-privacy-category h3 {
  margin-bottom: 5px;
  font-size: 1rem;
}

.ab-privacy-category p {
  margin: 0;
}

.ab-privacy-always-on {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  padding: 5px 9px;
  border-radius: 999px;
  background: #e9f6ed;
  color: #1d6332;
  font-size: .86rem;
  font-weight: 700;
  white-space: nowrap;
}

.ab-privacy-toggle {
  display: inline-flex;
  align-items: center;
  cursor: pointer;
}

.ab-privacy-toggle input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.ab-privacy-toggle span {
  position: relative;
  display: block;
  width: 50px;
  height: 30px;
  border-radius: 999px;
  background: #9da9b4;
  transition: background .15s ease;
}

.ab-privacy-toggle span::after {
  content: '';
  position: absolute;
  top: 4px;
  left: 4px;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 1px 4px rgba(0, 0, 0, .25);
  transition: transform .15s ease;
}

.ab-privacy-toggle input:checked + span {
  background: #1d6332;
}

.ab-privacy-toggle input:checked + span::after {
  transform: translateX(20px);
}

.ab-privacy-dialog-footer {
  border-top: 1px solid var(--privacy-border);
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: flex-end;
}

.ab-privacy-links {
  margin-top: 18px;
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}

.ab-privacy-footer-button {
  appearance: none;
  border: 0;
  background: transparent;
  color: inherit;
  padding: 0;
  font: inherit;
  text-align: left;
  text-decoration: underline;
  text-underline-offset: 2px;
  cursor: pointer;
}

html.ab-privacy-modal-open,
html.ab-privacy-modal-open body {
  overflow: hidden;
}

@media (max-width: 760px) {
  .ab-privacy-banner {
    left: 8px;
    right: 8px;
    bottom: 8px;
    border-radius: 14px;
  }

  .ab-privacy-banner-inner {
    grid-template-columns: 1fr;
    gap: 16px;
    padding: 17px;
  }

  .ab-privacy-actions,
  .ab-privacy-dialog-footer {
    display: grid;
    grid-template-columns: 1fr;
    width: 100%;
  }

  .ab-privacy-button {
    width: 100%;
  }

  .ab-privacy-modal {
    padding: 8px;
    align-items: end;
  }

  .ab-privacy-dialog {
    width: 100%;
    max-height: calc(100vh - 16px);
    border-radius: 16px 16px 10px 10px;
  }

  .ab-privacy-dialog-header,
  .ab-privacy-dialog-body,
  .ab-privacy-dialog-footer {
    padding: 18px;
  }
}

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