/* Minimal, clean UI - English */
:root {
  --cpm-bg: #ffffff;
  --cpm-overlay: rgba(0,0,0,.5);
  --cpm-border: #e5e7eb;
  --cpm-text: #111827;
  --cpm-muted: #6b7280;
  --cpm-primary: #127dab;
  --cpm-primary-hover: #0f6b90;
}

.cpm-btn {
  font: 500 14px/1.2 system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, "Apple Color Emoji","Segoe UI Emoji";
  padding: .6rem .9rem;
  border-radius: 10px;
  border: 1px solid var(--cpm-border);
  background: #fff;
  cursor: pointer;
}
.cpm-btn--primary {
  background: var(--cpm-primary);
  color: #fff;
  border-color: var(--cpm-primary);
}
.cpm-btn--primary:hover { background: var(--cpm-primary-hover); }
.cpm-btn--ghost { background: #fff; }

.cpm-footer-btn {
  position: fixed;
  right: 16px;
  bottom: 16px;
  z-index: 99998;
  box-shadow: 0 4px 16px rgba(0,0,0,.1);
}

.cpm-modal {
  position: fixed;
  inset: 0;
  display: none;
  z-index: 99999;
}
.cpm-modal.is-open { display: block; }
.cpm-modal__overlay {
  position: absolute; inset: 0; background: var(--cpm-overlay);
}
.cpm-modal__dialog {
  position: relative;
  max-width: 560px;
  margin: 10vh auto 0;
  background: var(--cpm-bg);
  border-radius: 16px;
  padding: 20px;
  box-shadow: 0 20px 50px rgba(0,0,0,.2);
}
.cpm-modal__header {
  display: flex; align-items: center; justify-content: space-between;
}
.cpm-modal__subtitle {
  color: var(--cpm-muted);
  margin: 10px 0 18px;
}
.cpm-modal__close {
  background: transparent;
  border: none;
  font-size: 28px;
  line-height: 1;
  cursor: pointer;
  color: var(--cpm-muted);
}
.cpm-switches { display: grid; gap: 14px; }
.cpm-switch {
  border: 1px solid var(--cpm-border);
  border-radius: 12px;
  padding: 12px;
}
.cpm-switch--locked { opacity: .8; }
.cpm-switch__row {
  display: flex; align-items: center; justify-content: space-between;
}
.cpm-switch__label { font-weight: 600; }
.cpm-switch__desc { color: var(--cpm-muted); display:block; margin-top: 6px; }

/* Simple slider look */
.cpm-switch input[type="checkbox"] {
  appearance: none;
  width: 44px; height: 24px;
  background: #e5e7eb;
  border-radius: 24px;
  position: relative;
  outline: none;
  cursor: pointer;
  transition: background .2s ease;
}
.cpm-switch input[type="checkbox"]:checked { background: var(--cpm-primary); }
.cpm-switch input[type="checkbox"]::after {
  content: "";
  position: absolute; top: 2px; left: 2px;
  width: 20px; height: 20px; border-radius: 50%;
  background: #fff; transition: transform .2s ease;
}
.cpm-switch input[type="checkbox"]:checked::after { transform: translateX(20px); }

.cpm-actions {
  display: flex; gap: 8px; justify-content: flex-end; margin-top: 18px;
}

/* Utility classes if you want to hide things when not allowed */
html:not(.cpm-allow-analytics) .requires-analytics,
html:not(.cpm-allow-marketing) .requires-marketing {
  display: none !important;
}
