/* Low route banner and opt-in main decoration. Load in the module layer,
   before the authoritative geometry/type/control/color layers. Images come
   exclusively from SSR's fixed map; CSS adds no URL and no route permission. */
:root body .page-banner {
  position: relative; isolation: isolate;
  min-block-size: 148px; margin-block: 0 1.5rem; padding: 1.2rem 1.5rem;
  background: var(--surface-raised); border: 1px solid var(--line);
  border-inline-start: 4px solid var(--brand); border-radius: .35rem;
  color: var(--ink); max-inline-size: 100%;
}
:root body .page-banner-image {
  position: absolute; z-index: -2; inset-block: 0; inset-inline-end: 0;
  inline-size: 44%; block-size: 100%; object-fit: cover; object-position: center;
  opacity: .28; pointer-events: none; border-radius: 0 .35rem .35rem 0;
}
:root body .page-banner::after {
  content: ''; position: absolute; z-index: -1; inset: 0;
  background: linear-gradient(90deg, var(--surface-raised) 0 55%, transparent 100%);
  pointer-events: none;
}
:root body .page-banner-content { max-inline-size: 68%; min-inline-size: 0; background-color: var(--surface-raised); }
:root body .page-banner .kicker { margin: 0 0 .35rem; color: var(--brand); font-size: .75rem; line-height: 1.7; }
:root body .page-banner h1 {
  margin: 0 0 .4rem; padding-block-end: .3rem; border-block-end: 1px solid var(--heading-line);
  font-size: clamp(1.55rem, 2.5vw, 2.2rem); line-height: 1.55; letter-spacing: 0;
  text-wrap: pretty; overflow-wrap: anywhere;
}
:root body .page-banner .page-banner-copy { color: var(--ink); font-size: 1rem; line-height: 1.85; margin: 0; text-indent: 0; }
:root body .app-header { margin-block-end: 0; }
:root body .app-header .member-breadcrumb { margin-block-end: .75rem; }
:root body .app-content { padding: clamp(1rem, 3vw, 2.75rem); inline-size: 100%; min-inline-size: 0; }
:root body .member-page-guide { margin-block: 0 1.5rem; padding: 1rem; }
:root body .focused-page-nav { display: flex; flex-wrap: wrap; gap: .5rem .75rem; margin-block: 0 1.25rem; }
:root body .focused-page-nav a { display: inline-flex; align-items: center; min-block-size: 44px; padding: .55rem .8rem; border: 1px solid var(--line-strong); border-radius: .2rem; background: var(--surface-raised); color: var(--ink); }
:root body .focused-page-nav a[aria-current='page'] { border-color: var(--brand); background: var(--brand-soft); font-weight: 700; }
:root body .focused-page-nav a:focus-visible { outline: 3px solid var(--brand); outline-offset: 3px; }
:root body .public-page .content-page { padding-block-start: 0; }
:root body .public-page .content-page > .page-banner { max-inline-size: none; }
:root body .public-page .related-pages { margin-block-start: 1.5rem; }
:root body .public-page .content-blocks { margin-block-start: 1.5rem; }
:root body .public-page .content-cta { padding-block: 2rem; }
:root body .email-auth-page > .page-banner { max-inline-size: 1120px; margin: 0 auto 1.5rem; }
:root body .email-auth-page { padding-block: 1.5rem 2.5rem; }
:root body .email-auth-layout { gap: 1.5rem; }
:root body .member-recovery-content { padding-block: 1.5rem 2rem; }

/* Decoration must be a direct child of an explicitly ambient main. Plain,
   private, unknown, stopped and recovery surfaces get no CSS-created image. */
:root body main.page-surface-ambient { position: relative; isolation: isolate; }
:root body main.page-surface-ambient > .page-ambient-image {
  position: absolute;
  z-index: -1;
  inset-block-start: 0;
  inset-inline: 0;
  inline-size: 100%;
  block-size: min(40rem, 100%);
  object-fit: cover;
  object-position: center top;
  opacity: .07;
  pointer-events: none;
  user-select: none;
}
:root body main.page-surface-plain > .page-ambient-image { display: none; }
:root body .page-content-surface { position: relative; }

@media (max-width: 640px) {
  :root body .page-banner { padding: var(--panel-space, 1rem); min-block-size: 132px; }
  :root body .page-banner-content { max-inline-size: 100%; }
  :root body .page-banner-image { inline-size: 40%; opacity: .12; }
  :root body .page-banner::after { background: linear-gradient(90deg, var(--surface-raised) 0 50%, transparent); }
  :root body main.page-surface-ambient > .page-ambient-image { block-size: min(28rem, 100%); opacity: .05; }
}
@media (forced-colors: active) {
  :root body :is(.page-banner-image, .page-ambient-image) { display: none; }
  :root body .page-banner { border-color: CanvasText; }
}
@media (prefers-reduced-motion: reduce) {
  :root body :is(.page-banner-image, .page-ambient-image) { animation: none; transition: none; }
}
@media print {
  :root body :is(.page-banner-image, .page-ambient-image) { display: none; }
  :root body .page-banner::after { content: none; }
  :root body .page-banner-content { max-inline-size: 100%; }
}
