/* Frame — auto-loaded for the frame snippet (site/snippets/layout/frame.php).
   Three tracks filling the viewport under the menubar: left column · centre ·
   right column. The side columns scroll independently. */

.frame {
  display: grid;
  grid-template-columns: var(--cols-page);
  grid-template-rows: 100%;
  height: calc(100vh - var(--menubar-h));
}

.frame__column {
  min-height: 0;
  height: 100%;
  overflow-y: auto;
  overscroll-behavior: contain;
}
.frame__column--left {
  order: 0;
  border-right: var(--border);
}
.frame__column--right {
  order: 2;
  border-left: var(--border);
}

.frame__center {
  order: 1;
  min-width: 0;
  min-height: 0;
}

/* Single column: the regions stack and the page scrolls as a whole. */
@media (max-width: 60rem) {
  .frame {
    grid-template-columns: 1fr;
    grid-template-rows: none;
    height: auto;
  }
  .frame__column {
    height: auto;
    overflow: visible;
  }
  .frame__column--left,
  .frame__column--right {
    border: 0;
    border-bottom: var(--border);
  }
}
