/* Shared page frame
   Use this for the outer geometry of collection, topic, and tool landing pages.
   The content pattern inside the frame may differ; the page should still feel
   like it belongs to the same MiniRetirement site. */

:root {
  --page-max: 1360px;
  --page-gutter: clamp(20px, 4vw, 56px);
  --page-top: clamp(40px, 5vw, 72px);
  --page-bottom: clamp(72px, 8vw, 112px);
  --page-rule: 1px solid var(--line);
}

/* Every top-level page uses the same quiet, in-flow masthead. */
body.has-site-nav { padding-top: 0; }
.site-nav {
  position: static;
  background: var(--paper);
  border-bottom: var(--page-rule);
  box-shadow: none;
  backdrop-filter: none;
}
.site-nav__inner {
  max-width: var(--page-max);
  height: 78px;
  min-height: 78px;
  padding-inline: var(--page-gutter);
}

/* A stable container and an unboxed opening statement across page types. */
.site-page--journal .journal-shell,
.site-page--topic .topic-shell,
.site-page--tools .page-shell {
  width: min(var(--page-max), 100%);
  max-width: var(--page-max);
  margin-inline: auto;
  padding: var(--page-top) var(--page-gutter) var(--page-bottom);
}

.site-page--topic .topic-hero,
.site-page--tools .page-header {
  margin-bottom: clamp(36px, 5vw, 64px);
  padding: 0 0 clamp(32px, 4vw, 48px);
  border: 0;
  border-bottom: var(--page-rule);
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  overflow: visible;
}
.site-page--topic .topic-hero::after { display: none; }

.site-page--journal .journal-hero {
  padding-bottom: clamp(32px, 4vw, 48px);
  border-bottom: var(--page-rule);
}
.site-page--journal .journal-filters { margin-top: 0; }

.site-page--tools .page-header { display: grid; gap: var(--space-4); }
.site-page--tools .page-header .lede { max-width: 62ch; }

@media (max-width: 1020px) {
  .site-nav__inner { height: 70px; min-height: 70px; }
}

@media (max-width: 720px) {
  .site-page--journal .journal-shell,
  .site-page--topic .topic-shell,
  .site-page--tools .page-shell {
    padding-top: 36px;
  }
}
