.sm-consent-banner,
.sm-consent-dialog {
  background: #fffdfa;
  color: var(--ink);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 12px 32px rgb(26 21 24 / .14);
  padding: 22px;
}
.sm-consent-banner {
  position: fixed;
  inset: auto auto max(24px, env(safe-area-inset-bottom)) max(24px, env(safe-area-inset-left));
  z-index: 1200;
  display: grid;
  gap: 16px;
  width: min(454px, calc(100% - 48px));
  border-top: 3px solid var(--rose);
}
.sm-consent-banner[hidden] { display: none; }
.sm-consent h2 { margin: 0 0 8px; padding-right: 36px; font: 400 27px/1.1 var(--serif); }
.sm-consent p { margin: 0; color: var(--muted); font-size: 14px; line-height: 1.5; }
.sm-consent a,
.sm-privacy-check a,
.sm-policy a { text-decoration: underline; text-underline-offset: .2em; }
.sm-consent a { color: var(--plum); }
.sm-consent-actions {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  border-top: 1px solid var(--line);
  padding-top: 14px;
}
.sm-consent-actions button {
  min-height: 44px;
  padding: 6px 8px;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: transparent;
  color: inherit;
  font: 600 14px/1.3 var(--sans);
  cursor: pointer;
}
.sm-consent-actions button[data-choice="accept"],
.sm-consent-actions button[data-choice="reject"] {
  background: var(--rose-pale);
  border-color: transparent;
  color: var(--ink);
}
.sm-consent-actions button:hover { border-color: var(--plum); }
.sm-consent :is(button, a, input):focus-visible {
  outline: 2px solid var(--plum);
  outline-offset: 2px;
}
.sm-consent-close {
  position: absolute;
  top: 7px;
  right: 7px;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 5px;
  background: transparent;
  color: inherit;
  font: 24px/1 var(--sans);
  cursor: pointer;
}
.sm-consent-dialog {
  width: min(510px, calc(100% - 24px));
  max-height: calc(100dvh - 24px);
  border-top: 3px solid var(--rose);
}
.sm-consent-dialog::backdrop { background: rgb(26 21 24 / .42); }
.sm-consent-dialog label {
  display: flex;
  gap: 8px;
  align-items: center;
  margin-block: 10px;
  padding: 9px 10px;
  border: 1px solid var(--line);
  border-radius: 4px;
  font-size: 14px;
}
.sm-consent-dialog .sm-consent-actions { margin-top: 16px; }
.sm-consent-dialog input { accent-color: var(--plum); width: 18px; height: 18px; }
.sm-consent-manage {
  border: 0;
  padding: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  text-decoration: underline;
  text-underline-offset: .2em;
  cursor: pointer;
}
[data-cookie-controls] .sm-consent-manage { margin-inline-start: 16px; }
.sm-privacy-check {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: start;
  gap: 9px;
  margin-block: 8px 16px;
  font-size: 14px;
}
form .sm-privacy-check label { display: inline; font: inherit; }
form .sm-privacy-check input[type="checkbox"] {
  width: 18px;
  height: 18px;
  min-height: 0;
  min-width: 0;
  margin: 3px 0 0;
  padding: 0;
  accent-color: var(--plum);
  appearance: auto;
  box-shadow: none;
}
form .sm-privacy-check input[type="checkbox"]:focus-visible {
  outline: 2px solid var(--plum);
  outline-offset: 3px;
}
.sm-policy { max-width: 760px; margin-inline: auto; padding: 42px 24px; }
.sm-policy h1 { margin-block: 24px; font: 400 42px/1.1 var(--serif); }
.sm-policy h2 { margin-block: 24px 8px; font: 400 26px/1.2 var(--serif); }
@media (max-width: 760px) {
  .sm-consent-banner {
    inset: auto 12px max(68px, calc(56px + env(safe-area-inset-bottom)));
    width: auto;
    max-height: 60dvh;
    overflow: auto;
    padding: 15px;
    gap: 12px;
  }
  .sm-consent h2 { font-size: 24px; }
  .sm-consent-actions { gap: 6px; }
  .sm-consent-actions button { padding-inline: 4px; font-size: 13px; }
}
