.cookie-choices {
  --cookie-edge: 24px;
  position: fixed;
  z-index: 155;
  inset-inline-start: max(var(--cookie-edge), env(safe-area-inset-left));
  bottom: calc(var(--cookie-edge) + env(safe-area-inset-bottom));
  width: min(404px, calc(100% - 2 * var(--cookie-edge) - env(safe-area-inset-left) - env(safe-area-inset-right)));
  max-height: 70dvh;
  overflow: auto;
  box-sizing: border-box;
  padding: 22px;
  border: 1px solid var(--pm-line);
  border-radius: var(--pm-r-lg);
  background: var(--pm-paper);
  color: var(--pm-ink);
  box-shadow: 0 12px 36px var(--pm-shadow);
  font-family: var(--pm-sans);
}

.cookie-choices[hidden], .cookie-choices [hidden] { display: none !important; }

.cookie-heading {
  display: flex;
  align-items: center;
  gap: 12px;
}

.cookie-heading img {
  flex: none;
  border-radius: 9px;
}

.cookie-heading h2 {
  margin: 0;
  font-size: 22px;
  line-height: 1.15;
  letter-spacing: -.025em;
}

.cookie-choices p {
  margin: 12px 0 16px;
  color: var(--pm-ink2);
  font-size: 15px;
  line-height: 1.5;
}

.cookie-choices a {
  color: var(--pm-link);
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.cookie-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.cookie-actions button {
  flex: 1 1 8rem;
  min-height: 44px;
  padding-inline: 12px;
  border: 1px solid var(--pm-line);
  cursor: pointer;
}

@media (max-width: 860px) {
  .cookie-choices {
    --cookie-edge: 12px;
    padding: 18px;
  }

  body:has(.actions) .cookie-choices {
    bottom: calc(78px + env(safe-area-inset-bottom));
    max-height: calc(100dvh - 98px - env(safe-area-inset-bottom));
  }
}
