.compact-projects-toggle,.compact-tools{display:none}
@media(max-width:1100px){
  html.compact-editor{scrollbar-gutter:stable}
  .compact-navigation-enabled .side{display:block;position:static;height:auto;min-height:0;padding:10px 16px;border-bottom:0}
  .compact-navigation-enabled .side>.stack{display:grid;grid-template-columns:1fr auto;align-items:center;gap:0 12px}
  .compact-navigation-enabled .side h1{margin:0;padding:0;line-height:1}
  .compact-navigation-enabled .side .brand-logo{display:block;width:128px;height:auto}
  .compact-navigation-enabled .compact-projects-toggle{display:flex;align-items:center;justify-content:center;gap:8px;min-height:42px;padding:0 11px;border:1px solid #39505a;border-radius:7px;background:transparent;color:#fff;font-family:inherit;font-size:12px;font-weight:600;cursor:pointer}
  .compact-projects-toggle svg{width:18px;height:18px;flex-shrink:0}
  .compact-projects-toggle svg:last-child{width:14px}
  .compact-projects-toggle[aria-expanded="true"] svg:last-child{transform:rotate(180deg)}
  .compact-navigation-enabled:not(.compact-projects-open) .side .side-actions,
  .compact-navigation-enabled:not(.compact-projects-open) .side>.project-nav-head,
  .compact-navigation-enabled:not(.compact-projects-open) .side>.bulk-panel,
  .compact-navigation-enabled:not(.compact-projects-open) .side>.projects,
  .compact-navigation-enabled:not(.compact-projects-open) .side>.side-profile{display:none!important}
  .compact-navigation-enabled .side .side-actions{grid-column:1/-1;display:grid;grid-template-columns:1fr 1fr;gap:10px;margin:14px 0 0}
  .compact-navigation-enabled .side .side-actions .btn{height:42px;min-height:42px}
  .compact-navigation-enabled .side>.project-nav-head{margin-top:16px}
  .compact-navigation-enabled .side>.projects{max-height:35vh;overflow-y:auto;margin:8px 0}
  .compact-navigation-enabled .side>.side-profile{display:flex;position:relative;margin-top:12px;padding-top:12px;min-height:0}
  .compact-navigation-enabled .side .side-update-popover{position:absolute;bottom:auto;top:100%;left:0;right:0;width:auto;z-index:200}
  .compact-navigation-enabled .main{display:block;min-height:calc(100dvh - 62px)}
  .compact-navigation-enabled .top{height:58px;min-height:58px;padding:0 16px;gap:10px;flex-direction:row;align-items:center}
  .compact-navigation-enabled .top .project-identity{flex:1;min-width:0}
  .compact-navigation-enabled .top-meta,.compact-navigation-enabled .top-title-input{width:100%;min-width:0}
  .compact-navigation-enabled .top .actions{width:auto;margin-left:0;flex-wrap:nowrap;gap:5px}
  .compact-navigation-enabled .top-actions-divider{display:none}
  .compact-navigation-enabled .workspace{display:flex;flex-direction:column;min-height:0;height:auto;overflow:visible}
  .compact-navigation-enabled .compact-tools{order:0;display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:6px;padding:10px 14px 6px}
  .compact-tools button{display:flex;align-items:center;justify-content:center;gap:7px;min-height:42px;padding:8px;border:1px solid var(--studio-border);border-radius:7px;background:#fff;color:#4c555f;font-family:inherit;font-size:12px;font-weight:600;cursor:pointer}
  .compact-tools button svg{width:18px;height:18px;flex-shrink:0}
  .compact-tools button[aria-expanded="true"]{border-color:#ffb2a8;background:var(--studio-accent-soft);color:var(--studio-accent)}
  .compact-tools button:focus-visible,.compact-projects-toggle:focus-visible{outline:2px solid var(--studio-accent);outline-offset:2px}
  .compact-navigation-enabled .content-column{order:1;display:none;height:auto;min-height:0;border:0;padding:6px 14px;gap:10px;overflow:visible}
  .compact-navigation-enabled[data-compact-panel="content"] .content-column{display:grid;grid-template-rows:44px minmax(0,1fr)}
  .compact-navigation-enabled[data-compact-panel="export"] .content-column{display:block}
  .compact-navigation-enabled .content-column>.content-panel.card{min-height:0!important;height:auto!important;max-height:44dvh;padding:14px!important;overscroll-behavior:contain}
  .compact-navigation-enabled[data-compact-panel="export"] .content-scope-tabs,
  .compact-navigation-enabled[data-compact-panel="export"] .content-panel>:not(.export-panel){display:none!important}
  .compact-navigation-enabled[data-compact-panel="content"] .content-panel>.export-panel{display:none!important}
  .compact-navigation-enabled[data-compact-panel="export"] .content-panel>.export-panel{display:block!important;margin:0;padding:0;border:0}
  .compact-navigation-enabled .preview-rail{display:contents}
  .compact-navigation-enabled .inspector-panel{order:2;display:none!important;width:auto;margin:6px 14px;height:auto!important;min-height:0!important;max-height:48dvh!important;overscroll-behavior:contain}
  .compact-navigation-enabled[data-compact-panel="settings"] .inspector-panel{display:flex!important}
  .compact-navigation-enabled .preview-main-card{order:3;min-height:0;height:auto;padding:10px 14px 0!important;overflow:visible}
  .compact-navigation-enabled .preview-controls{gap:6px}
  .compact-navigation-enabled .preview-edit-tools{width:100%;gap:6px;padding:4px;min-height:42px}
  .compact-navigation-enabled .edit-mode-note{margin:10px 2px 4px}
  .compact-navigation-enabled .stage{height:auto;padding:8px 4px 24px!important;overflow:visible}
  .compact-navigation-enabled .preview-stack{row-gap:18px}
}
@media(max-width:720px){
  .compact-navigation-enabled .side{padding:9px 14px}
  .compact-navigation-enabled .side .brand-logo{width:116px}
  .compact-navigation-enabled .top{display:grid;grid-template-columns:minmax(0,1fr) auto;height:auto;min-height:0;gap:3px 8px;padding:7px 14px}
  .compact-navigation-enabled .project-identity{grid-column:1;grid-row:1}
  .compact-navigation-enabled .top .top-field-body{min-height:32px}
  .compact-navigation-enabled .top-title-input{font-size:14px}
  .compact-navigation-enabled .autosave-state{grid-column:2;grid-row:1;height:32px;padding:0 4px}
  .compact-navigation-enabled .autosave-state[data-save-state="failed"],.compact-navigation-enabled .autosave-state[data-save-state="blocked"]{grid-column:1/-1;grid-row:3;justify-content:flex-start}
  .compact-navigation-enabled .top .actions{grid-column:1/-1;grid-row:2;justify-content:flex-end;gap:6px}
  .compact-navigation-enabled .actions .top-action-btn,.compact-navigation-enabled .actions .history-action{height:34px;min-height:34px}
  .compact-navigation-enabled .actions .top-action-btn{padding-inline:10px}
  .compact-navigation-enabled .actions .top-action-btn.icon-only{width:34px;padding:0}
  .compact-navigation-enabled .compact-tools{padding-top:8px}
  .compact-navigation-enabled .compact-tools button{font-size:12px;gap:5px}
  .compact-navigation-enabled .preview-toggle{font-size:11px;gap:4px}
  .compact-navigation-enabled .preview-edit-tools{gap:4px}
  .compact-navigation-enabled .format-manager-btn{padding-inline:9px!important}
}

@media(max-width:1100px){
  .compact-navigation-enabled .inspector-panel>.section-title{flex-basis:44px;min-height:44px;padding-left:16px!important}
  .compact-navigation-enabled .inspector-panel .focusbar{top:4px;right:8px}
  .compact-navigation-enabled .inspector-tabs{top:44px;flex-basis:56px;min-height:56px;padding:0 10px}
  .compact-navigation-enabled .inspector-tab{gap:4px}
  .compact-navigation-enabled .inspector-tab svg{width:17px;height:17px}
  .compact-navigation-enabled .inspector-panel .box-actions{position:static;padding:10px 16px!important}
  .compact-navigation-enabled .inspector-panel{max-height:42dvh!important}
}
