/* Config-only demo notice. Separate stylesheet because CSP style-src is 'self'
   (no inline styles). Hidden by default; only demo === true reveals it. */
.demo-notice {
  position: sticky;
  top: 0;
  z-index: 60;
  margin: 0;
  padding: 8px 16px;
  background: #7a4b00;
  color: #ffffff;
  font-weight: 600;
  text-align: center;
}
.demo-notice[hidden] { display: none; }

/* Stage D2 layout hook. applyDemoNotice sets data-demo-notice-visible on <html>
   only while the banner is revealed; without that attribute every rule below is
   inert and the production layout is byte-identical. No inline styles (CSP). */
:root[data-demo-notice-visible] { --demo-notice-offset: 44px; }
:root[data-demo-notice-visible] .demo-notice {
  box-sizing: border-box;
  min-height: var(--demo-notice-offset);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  line-height: 1.25;
}
/* Fixed chrome starts below the sticky banner, never under it. */
:root[data-demo-notice-visible] .sidebar { top: var(--demo-notice-offset); }
:root[data-demo-notice-visible] .skip-link:focus { top: calc(var(--demo-notice-offset) + 12px); }
@media (max-width: 820px) {
  :root[data-demo-notice-visible] { --demo-notice-offset: 64px; }
  :root[data-demo-notice-visible] .demo-notice { font-size: 13px; padding: 8px 12px; }
  /* The signed-out sidebar is static here: it already flows below the banner. */
  :root[data-demo-notice-visible] .signed-out .sidebar { top: 0; }
}
@media (max-width: 420px) {
  :root[data-demo-notice-visible] { --demo-notice-offset: 84px; }
}
:root[data-demo-notice-visible] .demo-notice[hidden] { display: none; }
