/* Publishing usability patch, 2026-11-01
 * Load AFTER publishing-glass-release-v1.css to preserve its cinematic visuals.
 * This file only removes scroll traps and keeps actions accessible. */
html:has(body.cw-screenflow),html:has(body.cps-screenfit),html:has(body.ps-services-page){
 height:auto!important;min-height:100%!important;
 overflow-x:hidden!important;overflow-y:auto!important;
 scrollbar-gutter:stable;
}
body.cw-screenflow,body.cps-body.cps-screenfit,body.ps-services-page.ps-tools-first{
 height:auto!important;min-height:100svh!important;
 max-height:none!important;overflow-x:hidden!important;overflow-y:visible!important;
}
body.cw-screenflow .cw-top{position:sticky!important;top:0!important;z-index:30!important}
body.cw-screenflow .cw-main{
 display:block!important;height:auto!important;min-height:0!important;
 max-height:none!important;overflow:visible!important;
 padding-bottom:100px!important;
}
body.cw-screenflow .cw-grid.cw-single-column{
 display:block!important;height:auto!important;min-height:0!important;
 max-height:none!important;overflow:visible!important;width:100%!important
}
body.cw-screenflow .cw-main-panel{
 display:flex!important;flex-direction:column!important;
 height:auto!important;min-height:0!important;max-height:none!important;
 overflow:visible!important;
}
body.cw-screenflow #cw-form{
 display:block!important;flex:none!important;
 height:auto!important;min-height:0!important;max-height:none!important;
 overflow:visible!important;overscroll-behavior:auto!important;
 padding:0 5px 20px 0!important;
}
body.cw-screenflow .cw-stage{min-height:0!important;overflow:visible!important;padding-bottom:22px}
body.cw-screenflow .cw-scroll-cue{display:none!important}
body.cw-screenflow .cw-controls{
 position:sticky!important;bottom:0!important;z-index:15!important;
 display:flex!important;flex-wrap:wrap!important;gap:10px!important;
 margin-top:0!important;padding:12px 13px calc(12px + env(safe-area-inset-bottom))!important;
 background:linear-gradient(120deg,rgba(7,33,41,.93),rgba(18,39,54,.92))!important;
 border:1px solid rgba(174,246,230,.65)!important;
 border-radius:13px!important;
 box-shadow:0 -9px 27px rgba(2,8,25,.41)!important;
 backdrop-filter:blur(15px)!important;
}
body.cw-screenflow .cw-controls button{
 cursor:pointer;min-height:43px!important;touch-action:manipulation;
}
body.cw-screenflow .cw-footer{display:flex!important}
body.cw-screenflow .cw-steps,body.cw-screenflow .cw-main-panel{
 scroll-margin-top:85px;
}
/* Creative Studio — page scroll rather than a trapped nested full-screen form. */
body.cps-body.cps-screenfit .cps-main,
body.cps-body.cps-screenfit .cps-workspace,
body.cps-body.cps-screenfit .cps-panel{
 display:block!important;height:auto!important;min-height:0!important;
 max-height:none!important;overflow:visible!important;
}
body.cps-body.cps-screenfit .cps-editor-layout{
 display:grid!important;grid-template-columns:minmax(0,1.04fr) minmax(340px,.96fr)!important;
 grid-template-rows:auto!important;align-items:start!important;
}
body.cps-body.cps-screenfit .cps-preview-shell{
 grid-column:1!important;grid-row:1!important;
 position:sticky!important;top:81px!important;
 max-height:calc(100dvh - 105px)!important;min-height:0!important;
 overflow:auto!important;
}
body.cps-body.cps-screenfit .cps-control-surface{
 grid-column:2!important;grid-row:1!important;
 height:auto!important;min-height:0!important;max-height:none!important;
 overflow:visible!important;
}
body.cps-body.cps-screenfit .cps-form-fields{
 display:flex!important;flex-direction:column!important;
 height:auto!important;max-height:none!important;min-height:0!important;
 flex:none!important;overflow:visible!important;
}
body.cps-body.cps-screenfit .cps-form-dock{
 position:sticky!important;bottom:0!important;z-index:8!important;
 padding-bottom:calc(12px + env(safe-area-inset-bottom))!important;
}
body.cps-body.cps-screenfit .cps-canvas-frame{
 height:auto!important;max-height:calc(100dvh - 255px)!important;
 min-height:0!important;display:flex!important;justify-content:center!important;
 align-items:center!important;
}
body.cps-body.cps-screenfit .cps-canvas-frame canvas{
 width:auto!important;height:auto!important;max-height:min(60dvh,700px)!important;
 max-width:100%!important;aspect-ratio:2/3!important;
}
body.cps-body.cps-screenfit .cps-check-layout,
body.cps-body.cps-screenfit .cps-print-layout{
 height:auto!important;min-height:0!important;max-height:none!important;
 overflow:visible!important;
}
body.ps-services-page.ps-tools-first .ps-single-setup{
 scroll-margin-top:84px;
}
@media(max-width:1099px){
 body.cps-body.cps-screenfit .cps-editor-layout{display:flex!important;flex-direction:column!important}
 body.cps-body.cps-screenfit .cps-preview-shell{
  grid-column:auto!important;grid-row:auto!important;
  position:relative!important;top:auto!important;
  max-height:none!important;overflow:visible!important;width:100%!important
 }
 body.cps-body.cps-screenfit .cps-control-surface{grid-column:auto!important;grid-row:auto!important;width:100%!important}
 body.cps-body.cps-screenfit .cps-canvas-frame{max-height:none!important}
 body.cps-body.cps-screenfit .cps-canvas-frame canvas{max-height:min(56dvh,560px)!important}
}
@media(max-width:650px){
 body.cw-screenflow .cw-controls{
  position:sticky!important;bottom:0!important;padding:9px 8px calc(10px + env(safe-area-inset-bottom))!important;
 }
 body.cw-screenflow .cw-controls button{flex:1 1 25%!important;min-height:40px!important;font-size:.7rem!important}
 body.cw-screenflow .cw-save-status{order:3;flex:1 1 100%;font-size:.65rem}
 body.cw-screenflow .cw-main{padding-bottom:90px!important}
 body.cps-body.cps-screenfit .cps-form-dock{position:relative!important;bottom:auto!important}
}
@media(max-height:620px){
 body.cps-body.cps-screenfit .cps-preview-shell{position:relative!important;top:auto!important;max-height:none!important}
}
@media(prefers-reduced-motion:reduce){
 html:has(body.cw-screenflow),html:has(body.cps-screenfit){scroll-behavior:auto!important}
}