/* Public header — invariant height, white surface, brand left.
   Geometry stays identical across public pages. */

.public-header {
  position: sticky;
  top: 0;
  z-index: 40;
  height: var(--header-public-h);
  background: var(--shell-header-bg);
  color: var(--shell-header-fg);
  border-bottom: 1px solid var(--shell-header-line);
  overflow: hidden;
  flex: 0 0 auto;
}
/* Two-layer geometry mirrors the landing grid:
   .public-header-pad   — full-width, page-inset (mobile safe-area padding)
   .public-header-row   — shared public max-width, centered public grid.
   The brand thus aligns with the label axis at every viewport. */
.public-header-pad {
  height: 100%;
}
.public-header-row {
  height: 100%;
  max-width: var(--max-public);
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  align-items: center;
  min-width: 0;
}
.brand {
  grid-column: 1;
  justify-self: start;
  font-family: var(--font-sans-semibold);
  font-weight: 400;
  font-size: var(--type-subhead);
  letter-spacing: 0;
  color: var(--shell-header-brand-fg);
  text-decoration: none;
  line-height: var(--leading-solid);
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
  gap: var(--control-gap);
}
/* Brand mark — small filled square, drawn in CSS so no extra asset
   request is needed. Inert by design (aria-hidden in the markup); the
   brand text carries the accessible name. */
.brand-mark {
  width: 0.75em;
  height: 0.75em;
  background: var(--shell-brand-mark-bg);
  flex: 0 0 auto;
}

/* Hairline rule above footer — full-bleed, mandatory on every page */
.footer-rule {
  height: 1px;
  background: var(--shell-footer-rule);
  width: 100%;
  flex: 0 0 auto;
}

.public-footer {
  min-height: var(--footer-public-h);
  overflow: visible;
  flex: 0 0 auto;
}
.public-footer-pad {
  height: 100%;
}
.footer-row {
  min-height: var(--footer-public-h);
  max-width: var(--max-public);
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  align-items: center;
  column-gap: var(--public-column-gap);
  row-gap: var(--space-s);
  padding-block: var(--space-s);
  min-width: 0;
}
.footer-row > * { min-width: 0; }
.footer-link {
  font-family: var(--font-sans-regular);
  font-size: var(--type-body);
  line-height: var(--leading-caption);
  color: var(--shell-footer-fg);
  text-decoration: none;
  transition: none;
}
.footer-link--privacy {
  grid-column: 1;
  justify-self: start;
  text-align: left;
  overflow-wrap: break-word;
}
.footer-link--auth {
  grid-column: 2;
  justify-self: center;
  text-align: center;
}
.footer-link--imprint {
  grid-column: 3;
  justify-self: end;
  text-align: right;
}
.footer-link--empty {
  pointer-events: none;
  visibility: hidden;
}
.footer-link:hover,
.footer-link:focus-visible {
  color: var(--shell-footer-link-hover);
  text-decoration: underline;
  text-underline-offset: 3px;
}
.footer-link[aria-current="page"] {
  color: var(--text-muted);
}

@media (max-width: 920px) {
  .footer-link {
    font-size: var(--type-caption);
  }
}
