@media(min-width:1100px){
 body .shell{width:calc(100% - 286px);max-width:none;margin-left:254px;margin-right:32px}
 body .studio{grid-template-columns:repeat(2,minmax(0,1fr))}
 body :is(.profile-stats,.wallet-summary,.service-list){max-width:none}
}
body .shell :is(.main-head,.topbar,.studio-panel,.profile-head,.wallet-summary){min-width:0}
body :is(.modal,.editor-controls){overscroll-behavior:contain}
body .modal{max-height:calc(100dvh - 32px);overflow:auto}
/* Dialogs must stay above the mobile navigation and preserve a visible close control. */
body .modal-backdrop{z-index:100;padding:12px}
body .modal-header{position:sticky;top:-24px;padding-top:12px;padding-bottom:12px;background:var(--panel);z-index:2}
body .modal-header .icon-btn{color:var(--text);background:var(--panel2);flex-shrink:0;min-width:36px;min-height:36px}
body:has(#modal-root:not(:empty)) .bottom-nav{visibility:hidden;pointer-events:none}
@media(max-width:799px){
 body .shell{padding-bottom:calc(110px + env(safe-area-inset-bottom,0px))}
 body .main-head{flex-wrap:wrap;gap:16px}
 body .main-head .search{width:100%;max-width:100%}
 body .bottom-nav{bottom:calc(10px + env(safe-area-inset-bottom,0px));max-width:calc(100% - 20px);padding-left:10px;padding-right:62px;grid-template-columns:repeat(5,minmax(0,1fr));z-index:60}
 body #floating-051{bottom:calc(28px + env(safe-area-inset-bottom,0px));right:23px;width:44px;height:44px;z-index:65;font-size:25px}
 body #quick-menu-051{bottom:calc(104px + env(safe-area-inset-bottom,0px));right:16px;max-height:calc(100dvh - 130px);overflow:auto;z-index:70}
 body .shell .hero{height:auto;min-height:280px;padding-bottom:62px}
 body .hero-dots{bottom:16px}
 body .hero-note{right:12px;bottom:18px;font-size:8px;max-width:50%}
 body .top-actions{gap:5px;flex-shrink:0}
 body .topbar .brand{min-width:0;white-space:nowrap}
 body .topbar .version{display:none}
 body .modal{max-width:calc(100vw - 24px);max-height:calc(100dvh - 24px);padding:24px 18px}
 body .studio{grid-template-columns:minmax(0,1fr)}
 body .studio-panel{padding:22px 18px}
 body .studio-panel :is(input,select,textarea){max-width:100%;min-width:0}
 body .editor-shell{height:100dvh;min-height:0;overflow:auto;padding-bottom:env(safe-area-inset-bottom,0px)}
 body .editor-header{flex-wrap:wrap;height:auto;min-height:56px;gap:10px}
 body .editor-footer{flex-wrap:wrap;gap:8px}
 body .editor-footer>*{min-width:0;flex:1 1 42%}
}
