/* Stock content is centred on the fixed side-arrow axis. The cover, custom
   grids, full bleed and frame-changing cinema remain deliberately authored.
   Captions occupy a separate 20px row: balance the visible composition,
   rather than letting that supporting row lift an image above the arrows. */
:is(html,#project-content-axis) body.page-project-detail #project-story>.story-slide:not(:is(.story-slide--custom,.story-slide--full_bleed,.story-slide--double_bleed,.story-slide--poster,.story-slide--reel)):not(:has(.story-layout--bleed)):not(:is([data-cinema-preset=image_to_copy],[data-cinema-preset=text_to_image],[data-cinema-preset=anchored_title],[data-cinema-preset=split_open],[data-cinema-preset=single_dual_single],[data-cinema-preset=reel])):has(.story-layout-boundary){
 --project-content-inset:var(--project-content-landscape-inset,max(80px,calc(var(--project-frame-top,12px) + 56px),calc(var(--project-frame-bottom,12px) + 56px)));
}
@media(orientation:landscape){
 :is(html,#project-content-axis) body.page-project-detail #project-story>.story-slide:not(:is(.story-slide--custom,.story-slide--full_bleed,.story-slide--double_bleed,.story-slide--poster,.story-slide--reel)):not(:has(.story-layout--bleed)):not(:is([data-cinema-preset=image_to_copy],[data-cinema-preset=text_to_image],[data-cinema-preset=anchored_title],[data-cinema-preset=split_open],[data-cinema-preset=single_dual_single],[data-cinema-preset=reel])):has(.story-layout-boundary){
  padding-top:var(--project-content-inset)!important;
  padding-bottom:calc(var(--project-content-inset) - var(--project-content-caption-space,0px))!important;
  padding-left:calc(var(--project-frame-left,28px) + 22px)!important;
  padding-right:calc(var(--project-frame-right,28px) + 22px)!important;
 }
 :is(html,#project-content-axis) body.page-project-detail #project-story>.story-slide:has(.story-layout:is(.story-layout--no-copy,.story-layout--text_image,.story-layout--statement,.story-layout--statement_image,.story-layout--diagram)>.story-layout__media>.story-media__item>.story-image-caption){--project-content-caption-space:20px}
}
@media(orientation:landscape) and (max-height:550px){
 /* Shallow phones have no spare footer band above the lower controls. Share
    their baseline, as desktop does, instead of overlaying the photographs. */
 body.page-project-detail .project-signature-row{
  bottom:calc(var(--project-frame-bottom,12px) + 22px);transform:translateY(50%);
 }
 :is(html,#project-content-axis) body.page-project-detail #project-story>.story-slide:has(.story-layout-boundary){
  --project-content-landscape-inset:max(60px,calc(var(--project-frame-top,12px) + 44px),calc(var(--project-frame-bottom,12px) + 44px));
 }
}
/* A bounded portrait composition is centred as a group, not each individual
   image. Long image-and-copy documents keep their natural reading height. */
@media(orientation:portrait){
 :is(html,#project-content-axis) body.page-project-detail #project-story>.story-slide:not(:is(.story-slide--custom,.story-slide--full_bleed,.story-slide--double_bleed,.story-slide--poster,.story-slide--reel)):not(:has(.story-layout--bleed)):has(.story-layout-boundary):not(:has([data-portrait-flow]:not([style*="--layout-frame-height"]))){
  --project-content-inset:max(104px,calc(var(--project-frame-top,12px) + 64px),calc(var(--project-frame-bottom,12px) + 86px));
  padding-top:var(--project-content-inset)!important;padding-bottom:var(--project-content-inset)!important;
  padding-left:calc(var(--project-frame-left,16px) + 22px)!important;padding-right:calc(var(--project-frame-right,16px) + 22px)!important;
 }
}
