/* Narrow-screen containment for the shared page controls and content bands. */
@media (max-width: 540px) {
  .content-page,
  .batch-one-page,
  .batch-base-page,
  .size-reference,
  .batch-tool,
  .spine-guide,
  .cover-guide {
    min-width: 0;
    max-width: 100%;
  }

  .page-actions {
    width: 100%;
    min-width: 0;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  }

  .page-action {
    width: 100%;
    min-width: 0;
    max-width: 100%;
    white-space: normal;
    overflow-wrap: anywhere;
  }

  .page-actions .page-action:only-of-type {
    grid-column: 1 / -1;
  }

  .page-action-status {
    min-width: 0;
    max-width: 100%;
    overflow-wrap: anywhere;
  }

  /* These bands previously used a wider desktop bleed than the current mobile gutter. */
  .batch-tool > aside,
  .spine-result,
  .dimension-result,
  .placed-result,
  .cover-result,
  .cover-formula,
  .novel-result,
  .spine-factors > div,
  .tool-directory-grid,
  .reading-list > div,
  .map-groups ul,
  .spine-case,
  .cover-boundary,
  .cover-steps,
  .cover-compare,
  .guide-route,
  .about-scope,
  .use-sequence,
  .start-map,
  .use-pages dl,
  .use-boundary,
  .map-summary,
  .size-cover-grid,
  .size-formula,
  .size-boundary {
    min-width: 0;
    max-width: 100%;
    margin-left: 0;
    margin-right: 0;
  }

  .batch-one-page h1,
  .batch-one-page p,
  .batch-tool > header h2,
  .batch-tool > header p,
  .batch-tool label,
  .batch-tool small,
  .batch-tool > aside p,
  .batch-related a,
  .guide-route a,
  .base-route a,
  .size-reference > h2,
  .size-reference-lead,
  .size-section-title h3,
  .size-section-title p,
  .size-cover-grid p,
  .size-workflow p,
  .size-boundary p,
  .size-next h3 {
    overflow-wrap: anywhere;
  }
}
