.cookie {
  position: fixed; left: 50%; bottom: 18px; transform: translateX(-50%); z-index: 1200;
  box-sizing: border-box; width: min(1040px, calc(100% - 32px)); max-height: calc(100dvh - 36px); overflow: auto;
  display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 20px; align-items: center;
  padding: 20px; border: 0; border-radius: 14px; background: var(--cookie-background, #fff); color: var(--oai-text-primary);
  box-shadow: 0 16px 48px rgb(0 0 0 / .18); font: 13px/1.6 var(--font-sans, sans-serif);
}
.cookie.is-hidden, .cookie [hidden] { display: none; }
.cookie p { margin: 0; color: var(--oai-text-secondary); font: inherit; }
.cookie a { color: inherit; text-decoration: underline; text-underline-offset: 3px; }
.cookie-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.cookie button { min-height: 42px; padding: 10px 14px; border: 0; border-radius: 8px; background: var(--oai-solid-btn-bg); color: var(--oai-solid-btn-text); font: inherit; font-weight: 550; cursor: pointer; }
.cookie button:hover { background: var(--oai-solid-btn-hover-bg); }
.cookie .cookie-customize { background: transparent; color: var(--oai-text-primary); text-decoration: underline; text-underline-offset: 4px; }
.cookie .cookie-customize:hover { background: var(--oai-surface-2); }
.cookie :focus-visible { outline: 2px solid var(--oai-focus); outline-offset: 3px; }
.cookie-preferences { grid-column: 1 / -1; display: grid; gap: 14px; padding-top: 18px; border-top: 1px solid var(--oai-border-subtle); }
.cookie-preferences-heading, .cookie-necessary { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.cookie-preferences h2 { margin: 0; color: var(--oai-text-primary); font-size: 17px; font-weight: 600; }
.cookie-necessary span { color: var(--oai-text-secondary); }
.cookie .cookie-save { justify-self: end; }
html[data-theme="dark"] .cookie { --cookie-background: #181818; }
@media (prefers-color-scheme: dark) { html:not([data-theme="light"]) .cookie { --cookie-background: #181818; } }
@media (max-width: 760px) {
  .cookie { grid-template-columns: minmax(0, 1fr); width: calc(100% - 24px); bottom: 12px; padding: 18px; gap: 14px; }
  .cookie-actions { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cookie-actions .cookie-customize { grid-column: 1 / -1; }
}
