/* Keep Theme's readable intermediate width for the profile only.
   Device grids, history, navigation and pouches use their established layout. */
@media screen and (min-width: 740px) and (max-width: 959.98px) and (orientation: portrait) {
  .pg-device-theme-layout #main_content.pgdv > .pgdv-profile {
    max-width: min(720px, var(--pg-content-width, 860px));
    margin-inline: auto;
  }
}

/* Match Theme 1.4.51's landscape gate and shared reader-width setting.
   The established 720px profile maximum still applies as the viewport widens. */
@media screen and (min-width: 740px) and (max-width: 1199.98px) and (orientation: landscape) and (min-height: 480px) {
  .pg-device-theme-layout #main_content.pgdv > .pgdv-profile {
    max-width: min(720px, var(--pgt-reader-measure, 680px));
    margin-inline: auto;
  }
}
