.acm-root {
  position: fixed;
  inset: 0;
  z-index: 10050;
  pointer-events: none;
}

.acm-root[hidden] { display: none; }

.acm-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.58);
  pointer-events: auto;
}

.acm-dialog {
  position: absolute;
  left: 50%;
  bottom: max(24px, env(safe-area-inset-bottom));
  width: min(680px, calc(100% - 32px));
  max-height: min(80vh, 720px);
  overflow-y: auto;
  box-sizing: border-box;
  padding: 28px;
  color: #fff;
  background: #111;
  border: 1px solid #4a4a4a;
  border-radius: 12px;
  box-shadow: 0 18px 54px rgba(0, 0, 0, 0.45);
  transform: translateX(-50%);
  pointer-events: auto;
}

.acm-dialog[hidden] { display: none; }
.acm-dialog h2 { margin: 0 0 12px; color: #fff; font-size: 1.35rem; }
.acm-dialog p { margin: 0 0 16px; line-height: 1.6; color: rgba(255, 255, 255, 0.86); }
.acm-policy-link a { color: #fff; text-decoration: underline; }
.acm-actions { display: flex; flex-wrap: wrap; gap: 10px; }

.acm-button {
  flex: 1 1 170px;
  min-height: 44px;
  padding: 10px 14px;
  border: 1px solid #fff;
  border-radius: 6px;
  font: inherit;
  font-weight: 600;
  cursor: pointer;
}

.acm-button-primary,
.acm-button-secondary { color: #111; background: #fff; }
.acm-button:hover { color: #fff; background: #2f2f2f; }
.acm-button:focus-visible,
.acm-close:focus-visible { outline: 3px solid #77bfff; outline-offset: 3px; }

.acm-preferences { top: 50%; bottom: auto; transform: translate(-50%, -50%); }
.acm-category {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  min-height: 66px;
  padding: 13px 0;
  border-top: 1px solid #3c3c3c;
}

.acm-category strong,
.acm-category span > span { display: block; }
.acm-category strong { margin-bottom: 3px; }
.acm-category span > span { color: rgba(255, 255, 255, 0.72); font-size: 0.9rem; line-height: 1.4; }
.acm-always-active { color: #fff; font-size: 0.9rem; font-weight: 700; white-space: nowrap; }
.acm-category input { position: absolute; opacity: 0; }
.acm-toggle { position: relative; width: 46px; height: 26px; flex: 0 0 46px; border-radius: 999px; background: #6b6b6b; }
.acm-toggle::after { content: ''; position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; border-radius: 50%; background: #fff; transition: transform .18s ease; }
.acm-category input:checked + .acm-toggle { background: #fff; }
.acm-category input:checked + .acm-toggle::after { transform: translateX(20px); background: #111; }
.acm-category input:focus-visible + .acm-toggle { outline: 3px solid #77bfff; outline-offset: 3px; }
.acm-close { position: absolute; top: 10px; right: 14px; color: #fff; background: transparent; border: 0; font-size: 30px; line-height: 1; cursor: pointer; }
.acm-refresh-status { font-size: .9rem; font-weight: 700; }

@media (max-width: 600px) {
  .acm-dialog { width: calc(100% - 20px); padding: 22px 18px; bottom: max(10px, env(safe-area-inset-bottom)); }
  .acm-preferences { top: 50%; bottom: auto; }
  .acm-actions { display: grid; grid-template-columns: 1fr; }
  .acm-button { width: 100%; }
  .acm-category { gap: 12px; }
}

footer .cookie-settings {
  padding: 0;
  color: inherit;
  background: transparent;
  border: 0;
  font: inherit;
  text-transform: inherit;
  cursor: pointer;
}
