/* Presentation only. Combined first cookie notice (consent.js) and Meta status.
   Consent logic and storage stay in consent.js and meta-marketing.js. */

/* Blocking first notice: dimmed full-viewport overlay, centred on every screen size. */
.consent-dialog.consent-first {
  z-index: 90;
  background: rgba(28, 28, 28, 0.66);
  align-items: center;
  justify-content: center;
  justify-items: center;
  padding: max(0.75rem, env(safe-area-inset-top)) max(0.75rem, env(safe-area-inset-right)) max(0.75rem, env(safe-area-inset-bottom)) max(0.75rem, env(safe-area-inset-left));
  overflow-y: auto;
  overscroll-behavior: contain;
}

.consent-first .consent-panel {
  width: min(100%, 36rem);
  max-height: calc(100vh - 1.5rem);
  max-height: calc(100dvh - 1.5rem);
  box-shadow: 0 18px 48px rgba(28, 28, 28, 0.35);
  padding: 1.4rem 1.3rem 1.4rem;
}

.consent-first h2:focus,
.consent-first h2:focus-visible {
  outline: none;
}

.consent-first .consent-panel a:focus-visible,
.consent-dialog .choice-btn:focus-visible,
.consent-dialog input:focus-visible {
  outline: 3px solid var(--red-text);
  outline-offset: 2px;
}

.consent-actions.consent-actions-two {
  grid-template-columns: 1fr 1fr;
  margin-top: 1rem;
}

/* Page behind the first notice cannot scroll; consent.js restores the position. */
html.consent-locked,
body.consent-locked {
  overflow: hidden;
}

body.consent-locked {
  position: fixed;
  width: 100%;
}

/* Discreet live status for screen readers; choices are changed in the footer dialog. */
.meta-marketing-status {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

@media print {
  .consent-dialog.consent-first { display: none !important; }
  html.consent-locked,
  body.consent-locked { overflow: visible; position: static; }
}
