/* P191 mobile layout owner. Historical desktop decoration stays intact.
   Grid reserves real rows for header, catalogue, viewport, and footer. */
#p191Camera{display:flex;align-items:center;gap:6px}#p191Camera button{min-height:36px;padding:4px 8px}#p191Camera [aria-pressed=true]{outline:2px solid currentColor}
html.p191-mobile,html.p191-mobile body{height:100%!important;overflow:hidden!important;overscroll-behavior:none!important}
html.p191-mobile #app:not([hidden]){position:fixed!important;inset:0!important;box-sizing:border-box!important;width:100%!important;max-width:none!important;height:var(--p191-height,100dvh)!important;min-height:0!important;padding:env(safe-area-inset-top) env(safe-area-inset-right) env(safe-area-inset-bottom) env(safe-area-inset-left)!important;margin:0!important;display:block!important;overflow:hidden!important;z-index:25!important;background:var(--matiere)!important}
html.p191-mobile #app .workspace{position:relative!important;box-sizing:border-box!important;display:grid!important;grid-template-rows:auto 96px minmax(0,1fr) 44px!important;grid-template-columns:minmax(0,1fr)!important;gap:0!important;padding:0!important;margin:0!important;width:100%!important;height:100%!important;min-height:0!important;max-width:none!important;overflow:hidden!important}
html.p191-mobile #app .workspace:after{display:none!important}
html.p191-mobile #app .topline,html.p191-mobile #editorToolbar,html.p191-mobile #tools,html.p191-mobile #editorBelow,html.p191-mobile #p74Guide,html.p191-mobile #p53OtherTools{display:none!important}
html.p191-mobile #p53Top{grid-row:1!important;position:relative!important;inset:auto!important;display:grid!important;grid-template-areas:'brand world actions'!important;grid-template-columns:max-content 34px minmax(0,1fr)!important;align-items:center!important;gap:4px!important;box-sizing:border-box!important;margin:0!important;padding:0 6px!important;width:100%!important;height:44px!important;min-height:44px!important;max-height:none!important;z-index:12!important}
html.p191-mobile #p53Top .p53-brand{grid-area:brand!important;display:flex!important;min-width:0!important}html.p191-mobile .p53-brand small{display:none!important}
html.p191-mobile #p189Home{display:flex!important;align-items:center!important;min-height:44px!important;min-width:78px!important;margin:0!important;padding:4px!important;font-size:16px!important;background:transparent!important;color:var(--fond)!important}
html.p191-mobile #p64WorldDock{grid-area:world!important}html.p191-mobile #p53Top .p53-top-actions{grid-area:actions!important;display:flex!important;flex-wrap:nowrap!important;justify-content:flex-start!important;min-width:0!important;width:100%!important;overflow-x:auto!important;overflow-y:hidden!important;gap:6px!important;touch-action:pan-x!important}
html.p191-mobile #p53Top .p53-top-actions>*{flex:0 0 auto!important;min-height:40px!important;padding:4px 6px!important;font-size:12px!important}
html.p191-mobile #p53Test{order:-2!important}
html.p191-mobile #p53Tools.p60-palette{grid-row:2!important;box-sizing:border-box!important;display:flex!important;flex-direction:column!important;align-items:stretch!important;position:relative!important;inset:auto!important;width:100%!important;height:96px!important;min-height:0!important;max-height:none!important;padding:0 6px!important;margin:0!important;gap:0!important;overflow:hidden!important}
html.p191-mobile #p189CategoryBar{display:flex!important;flex:0 0 30px!important;gap:4px!important;min-height:0!important;overflow-x:auto!important;touch-action:pan-x!important}
html.p191-mobile #p189CategoryBar button{flex:0 0 auto!important;border:0!important;border-bottom:2px solid transparent!important;background:transparent!important;color:var(--fond)!important;min-height:30px!important;padding:3px 10px!important;font-size:12px!important;white-space:nowrap!important}
html.p191-mobile #p189CategoryBar [aria-pressed=true]{border-bottom-color:var(--fond)!important}
html.p191-mobile #p53Tools .p60-group{display:none!important}
html.p191-mobile #p53Tools .p60-group.p189-selected{display:flex!important;flex:1 1 0!important;min-height:0!important;height:66px!important;min-width:0!important;max-width:100%!important;overflow-x:auto!important;overflow-y:hidden!important;touch-action:none!important;overscroll-behavior:contain!important}
html.p191-mobile #p53Tools .p60-group-title{display:none!important}
html.p191-mobile #p53Tools .p60-group-contents{display:flex!important;flex-wrap:nowrap!important;width:max-content!important;min-width:100%!important;flex-shrink:0!important;gap:8px!important;overflow:visible!important}
html.p191-mobile #p53Tools .p60-tool{flex:0 0 66px!important;box-sizing:border-box!important;width:66px!important;min-width:66px!important;max-width:66px!important;height:64px!important;min-height:0!important;max-height:none!important;padding:1px!important;touch-action:none!important;user-select:none!important;-webkit-touch-callout:none!important}
html.p191-mobile #p53Tools .p60-icon,html.p191-mobile #p53Tools .p60-silhouette{width:46px!important;height:34px!important}
html.p191-mobile #p53Tools .p60-name{font-size:10px!important;line-height:1.05!important;max-width:66px!important}
html.p191-mobile #stageShell.stage-shell{grid-row:3!important;align-self:stretch!important;justify-self:stretch!important;position:relative!important;inset:auto!important;box-sizing:border-box!important;width:100%!important;min-width:0!important;max-width:none!important;height:auto!important;min-height:0!important;max-height:none!important;aspect-ratio:auto!important;margin:0!important;padding:0!important;overflow:hidden!important;touch-action:none!important;overscroll-behavior:none!important}
html.p191-mobile #stage,html.p191-mobile #p53Context,html.p191-mobile #p53Context button{touch-action:none!important;user-select:none!important;-webkit-touch-callout:none!important}
html.p191-mobile #p62RobotDock{grid-row:4!important;position:relative!important;inset:auto!important;display:flex!important;justify-content:space-between!important;align-items:center!important;box-sizing:border-box!important;width:100%!important;height:44px!important;min-height:0!important;max-height:none!important;padding:0 6px!important;margin:0!important;overflow-x:auto!important;gap:8px!important}
html.p191-mobile #p62RobotDock>*{flex-shrink:0!important}html.p191-mobile #robotTest{min-height:36px!important;font-size:11px!important}
html.p191-mobile #p126SelectionBar{max-width:calc(100% - 12px)!important;overflow-x:auto!important;max-height:48px!important}
html.p191-mobile body.p53-playing #app .workspace{grid-template-rows:44px minmax(0,1fr) 76px!important;padding:0!important}
html.p191-mobile body.p53-playing #stageShell{grid-row:2!important}
html.p191-mobile body.p53-playing #p53Tools,html.p191-mobile body.p53-playing #p62RobotDock,html.p191-mobile body.p53-playing #p180KofiPlayDock,html.p191-mobile body.p53-playing .stage-foot{display:none!important}
html.p191-mobile body.p53-playing #p53Top .p53-top-actions>:not(#p53Test){display:none!important}
html.p191-mobile body.p53-playing #touchPad:not([hidden]){position:fixed!important;box-sizing:border-box!important;display:flex!important;justify-content:space-between!important;align-items:center!important;left:max(10px,env(safe-area-inset-left))!important;right:max(10px,env(safe-area-inset-right))!important;bottom:calc(6px + env(safe-area-inset-bottom))!important;width:auto!important;max-width:none!important;height:64px!important;margin:0!important;z-index:90!important;pointer-events:none!important;touch-action:none!important}
html.p191-mobile #touchPad button{width:60px!important;height:60px!important;min-width:60px!important;min-height:60px!important;pointer-events:auto!important;touch-action:none!important}
@media(max-width:500px) and (orientation:portrait){html.p191-mobile body.p53-editing #p53Top{height:84px!important;grid-template-areas:'brand world' 'actions actions'!important;grid-template-columns:minmax(0,1fr) 40px!important;grid-template-rows:42px 42px!important}}
@media(orientation:landscape){html.p191-mobile #app .workspace{grid-template-rows:44px 82px minmax(0,1fr) 40px!important}html.p191-mobile #p53Tools.p60-palette{height:82px!important}html.p191-mobile #p53Tools .p60-group.p189-selected{height:52px!important}html.p191-mobile #p53Tools .p60-tool{height:52px!important}html.p191-mobile #p53Tools .p60-icon,html.p191-mobile #p53Tools .p60-silhouette{height:25px!important}html.p191-mobile #p62RobotDock{height:40px!important}html.p191-mobile body.p53-playing #app .workspace{grid-template-rows:44px minmax(0,1fr) 70px!important}}
html.p191-mobile body.p53-playing #p53Top{grid-template-areas:'brand score actions'!important;grid-template-columns:max-content minmax(0,1fr) auto!important}
html.p191-mobile body.p53-playing #p64WorldDock{display:none!important}
html.p191-mobile #p190ScoreSlot{grid-area:score!important;min-width:0!important;overflow:hidden!important}
html.p191-mobile #p190ScoreSlot #chronoHud{position:static!important;display:flex!important;gap:6px!important;align-items:center!important;color:var(--fond)!important}
html.p191-mobile #p190ScoreSlot .chrono-best-holder,html.p191-mobile #p190ScoreSlot .chrono-current-label,html.p191-mobile #p190ScoreSlot .chrono-best-label{display:none!important}
html.p191-mobile #p190ScoreSlot .chrono-current-time{font-size:18px!important}html.p191-mobile #p190ScoreSlot .chrono-best-time{font-size:11px!important}

/* Same existing selection solver, a compact complete action row on touch screens. */
html.p191-mobile #p126SelectionBar{flex-wrap:nowrap!important;min-height:48px!important;height:48px!important;max-height:48px!important;padding:3px!important;gap:4px!important;overflow:visible!important}
html.p191-mobile #p126SelectionBar .p126-selection-label{display:none!important}
html.p191-mobile #p126SelectionBar button{min-height:42px!important;max-height:42px!important;min-width:82px!important;padding:6px!important;font-size:12px!important}
html.p191-mobile #p189Home{font-weight:900!important}
