/* Consent UI is separate from page content and existing form/navigation styles. */
#otmd-consent [hidden], .consent-footer[hidden] { display: none !important; }
/* While the notice is open, reserve its actual height in the viewport.
 * The page scrolls above it; no fixed overlay or guessed bottom spacer is needed.
 * Removing the notice restores the normal document layout automatically. */
body:has(#consent-banner:not([hidden])) { display: flex; flex-direction: column; height: 100dvh; overflow: auto; }
/* Desktop header CSS uses display: contents on this wrapper. A scrollable
 * flex child needs a real box at every width while the notice is visible. */
body:has(#consent-banner:not([hidden])) > #page-background { display: block; flex: 1 1 auto; min-height: 0; overflow-y: auto; }
body:has(#consent-banner:not([hidden])) > #otmd-consent { flex: 0 0 auto; min-width: 0; }
.consent-banner { max-height: max(80px, calc(100dvh - 160px)); overflow-y: auto; background: var(--color-pale-blue); color: var(--color-dark-blue); border-top: 2px solid var(--color-dark-blue); padding: 16px 0; }
.consent-banner__inner { display: flex; align-items: center; gap: 24px; flex-wrap: wrap; }
.consent-banner__inner > div:first-child { flex: 1 1 360px; }
.consent-banner h2, .consent-dialog h2 { margin: 0 0 12px; font-size: 1.4rem; }
.consent-banner p, .consent-dialog p { margin: 12px 0; }
.consent-actions { display: flex; flex-wrap: wrap; gap: 12px; }
.consent-actions button { font: inherit; cursor: pointer; min-height: 44px; border: 2px solid var(--color-dark-blue); border-radius: 4px; padding: 8px 16px; background: var(--color-white); color: var(--color-dark-blue); }
.consent-actions button:hover { background: var(--color-pale-blue); }
.consent-actions button:focus-visible, #otmd-consent a:focus-visible, .consent-choice input:focus-visible { outline: 3px solid var(--color-primary); outline-offset: 4px; }
#otmd-consent a { color: var(--color-dark-blue); text-decoration: underline; }
.consent-dialog { width: min(640px, calc(100% - 32px)); max-height: calc(100dvh - 32px); overflow: auto; padding: 24px; border: 2px solid var(--color-dark-blue); border-radius: 8px; background: var(--color-white); color: var(--color-dark-blue); font: inherit; }
.consent-dialog::backdrop { background: rgb(0 0 0 / 55%); }
.consent-choice { display: flex; align-items: center; gap: 12px; min-height: 44px; margin: 16px 0; }
.consent-choice input { width: 24px; height: 24px; accent-color: var(--color-primary); }
.consent-footer button { appearance: none; font: inherit; cursor: pointer; min-height: 44px; max-width: 100%; border: 0; border-radius: 0; margin: 0; padding: 0; background: transparent; color: var(--color-pale-blue); text-align: left; text-decoration: none; }
.consent-footer button:hover { color: var(--color-amber); }
.consent-footer button:focus-visible { outline: 3px solid var(--color-amber); outline-offset: 3px; }
.consent-status, .consent-noscript { padding-block: 16px; color: var(--color-dark-blue); background: var(--color-white); }
@media (max-width: 480px) {
  .consent-actions { width: 100%; }
  .consent-actions button { flex: 1 1 100%; }
  .consent-dialog { padding: 16px; }
}
