/* Keep right-top ownership independent of the ribbon's intrinsic height. */
.excel-shell61.app.workspace71.workspace78.workspace80{grid-template-rows:auto minmax(0,1fr) 44px!important;--inspector80:max(360px,var(--right-width71,360px));--inspector-width64:var(--inspector80)!important}
.excel-shell61.app.workspace71.workspace78.workspace80:not(.right-collapsed){grid-template-columns:140px minmax(0,1fr) var(--inspector80)!important}
.excel-shell61.app.workspace80>.right{grid-column:3!important;grid-row:1/-1!important;padding:8px!important;overflow:visible!important;align-self:stretch;position:relative!important;inset:auto!important;width:auto!important}
.excel-shell61.app.workspace71.workspace80>.right>.right-inner{height:100%;gap:5px;overflow:visible!important}
.workspace80 .workspace-ribbon58{grid-column:2!important;align-self:start;height:auto!important;min-height:0!important;overflow:visible!important}
.workspace80 .system-area61{padding:8px;gap:6px;align-self:stretch}
.workspace80 .quick-row62{flex-wrap:wrap!important;overflow:visible!important;min-height:34px;gap:4px!important}
.workspace80 .document-name66{flex:1 1 175px}
.workspace80 .document-name66 input{flex:1;min-width:80px!important;max-width:160px}
.workspace80 .ribbon-panels58{height:auto!important;max-height:none!important;overflow:visible!important}
.workspace80 .ribbon-panels58>[role=tabpanel]{height:auto!important;min-height:0!important;max-height:none!important;padding:6px 0!important;overflow:visible!important;min-width:0!important}
/* Flex wrapping uses real content height; no clipped fourth direction button. */
.workspace80 #ribbon-panel-common.common78{display:flex!important;flex-wrap:wrap;align-items:flex-start!important;gap:8px!important;min-width:0!important}
.workspace80 .formatting-ribbon{flex:0 1 var(--font-width78,250px);width:var(--font-width78,250px);max-width:100%}
.workspace80 .excel-format66{grid-template-rows:auto auto auto auto!important;gap:4px 0!important;height:auto!important;align-items:start!important}
.workspace80 .excel-format66 .font-group65>.ribbon-controls,.workspace80 .excel-format66 .text-group63>.ribbon-controls{flex-wrap:wrap!important;gap:4px!important}
.workspace80 .fit-inline77{flex-wrap:wrap!important;white-space:normal!important;margin:0!important}
.workspace80 .appearance71{flex:0 0 170px;align-self:flex-start;gap:4px!important}
.workspace80 .appearance71 .direct-options{flex-wrap:wrap!important}
.workspace80 .ribbon-divider78{flex:0 0 8px;height:126px}
.workspace80 .geometry-group63{display:grid!important;flex:0 0 104px;width:104px!important;min-width:104px!important;grid-template-columns:repeat(2,minmax(0,1fr))!important;grid-template-rows:auto auto auto!important;gap:4px!important;max-width:none!important}
.workspace80 .geometry-group63>strong{grid-column:1/-1}
.workspace80 .geometry-group63>.btn{height:auto!important;min-height:46px!important;width:100%!important;min-width:0!important;white-space:nowrap!important}
.workspace80 .geometry-inline77{display:block!important;flex:0 0 218px;width:218px!important;min-width:218px!important;max-width:218px!important}
.workspace80 .geometry-inline77>div,.workspace80 .geometry-inline77 .grid-controls,.workspace80 .geometry-inline77 .geometry-fields77{display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr));gap:4px!important}
.workspace80 .geometry-inline77 label{display:flex!important;flex-direction:column;gap:2px;width:auto!important;min-width:0;margin:0!important}
.workspace80 .geometry-inline77 label .field{width:100%!important;margin:0!important}
.workspace80 #ribbon-panel-layout.layout78,.workspace80 #ribbon-panel-view.view78{display:flex!important;flex-wrap:wrap;gap:12px!important;min-width:0!important}
.workspace80 .ribbon-section78{flex:1 1 200px;min-height:0!important;max-width:300px;gap:6px!important}
.workspace80 #ribbon-panel-insert{display:flex;flex-wrap:wrap;min-width:0!important}
.workspace80 .favorite-materials66{grid-template-columns:repeat(6,49px)!important}
.workspace80 .empty-common79{flex-direction:column!important;gap:8px!important}
/* Direct readable rows; labels and action buttons never compete for one line. */
.workspace80 .appearance-top78{display:flex;flex-wrap:wrap;flex:none;padding:0 0 6px!important;gap:5px!important;width:100%;overflow:visible!important}
.workspace80 .appearance-top78 .visibility73{width:100%!important;min-width:0!important;display:flex;flex-wrap:wrap;gap:12px!important}
.workspace80 .appearance-top78 .visibility73 label{flex:none!important;white-space:nowrap!important;word-break:keep-all}
.workspace80 .appearance-top78 .compact-actions74{width:100%!important;min-width:0!important;margin:0!important;gap:5px!important}
.workspace80 .appearance-top78>label{white-space:nowrap;flex:none;min-width:0}
.workspace80 .appearance-top78 .chair-options59 .btn{white-space:nowrap!important;min-width:0!important}
.workspace80 .appearance-top78 .direct-options{display:flex;gap:4px}
.workspace80 [data-right-pane=settings]{flex:0 0 auto!important;overflow:visible!important;min-height:0!important;padding:0!important}
.workspace80 .right .selection-bar73{display:grid!important;grid-template-columns:minmax(0,1fr) auto auto;gap:5px!important;padding:2px 0!important}
.workspace80 .right .selection-bar73 .btn{flex:none!important;width:auto!important;margin:0!important;white-space:nowrap!important}
.workspace80 .right .selection-bar73 #delete-seat{flex-basis:auto!important;grid-column:auto}
.workspace80 .seat-editor{padding:0!important;margin:0!important}
.workspace80 .seat-editor .inspector-field{grid-template-columns:minmax(0,1fr)!important;margin:3px 0!important}
.workspace80 .seat-editor label{line-height:1.4;word-break:normal}
.workspace80 .seat-editor .field{padding:4px 6px!important}
.workspace80 .seat-editor .grid-controls{grid-template-columns:repeat(2,minmax(0,1fr));gap:6px!important;margin:0!important}
.workspace80 .seat-editor .seat-quick70{margin:2px 0!important;flex-wrap:wrap!important}
.workspace80 .seat-text73{margin:4px 0!important;padding:4px 0!important}
.workspace80 .seat-text73 textarea{height:48px!important;min-height:48px!important}
.workspace80 .seat-text73 .button-row{display:flex!important;gap:4px!important}
.workspace80 .seat-text73 .button-row .btn{width:auto!important;flex:1;white-space:nowrap}
.workspace80 .seat-actions79{gap:5px;margin-top:4px}
.workspace80 .seat-actions79 label{display:grid!important;grid-template-columns:auto minmax(0,1fr);gap:8px}
.workspace80 .seat-actions79 select{width:100%;min-width:0}
.workspace80 .right .inspector-display73{margin:4px 0!important;padding:0!important}
.workspace80 .right .table-settings73,.workspace80 .right .chair-settings70{display:block!important;padding:6px!important;margin:4px 0!important}
.workspace80 .table-settings73>strong{font-size:14px!important;margin-bottom:4px!important}
.workspace80 .table-settings73 p{margin:4px 0;font-size:12px;line-height:1.4}
.workspace80 .table-settings73 .size-fields73,.workspace80 .desk-edges73{gap:5px;margin:4px 0;grid-template-columns:repeat(2,minmax(0,1fr))}
.workspace80 .table-settings73 .btn{min-height:28px!important;margin:0!important;white-space:nowrap}
.workspace80 .table-settings73 .desk-layout-actions73{gap:4px}
.workspace80 .table-settings73 .error73:empty{display:none}
.workspace80 .arc-settings78{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:5px}
.workspace80 .arc-settings78>strong,.workspace80 .arc-settings78>.btn,.workspace80 .arc-settings78>p{grid-column:1/-1}
/* Center the scaled sheet, and allow left-edge access when it exceeds the area. */
.excel-shell61.app.workspace80 .workspace{display:block!important;padding:58px 20px 20px!important}
.excel-shell61.app.workspace80 .canvas-shell{margin-left:auto!important;margin-right:auto!important;flex:none}
.workspace80.right-collapsed{--inspector-width64:0px!important}
.workspace80.right-collapsed .workspace-ribbon58{grid-column:2/4!important}
.workspace80 .canvas-quick64{right:calc(var(--inspector-width64) + 20px)!important}
/* Short screens use a wider, two-column inspector instead of hiding controls. */
@media(max-height:780px) and (min-width:1050px){
 .excel-shell61.app.workspace71.workspace78.workspace80{--inspector80:max(460px,var(--right-width71,360px))}
 .workspace80 [data-right-pane=settings]{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:5px 8px}
 .workspace80 .selection-bar73{grid-column:1/-1}
 .workspace80 .seat-editor{grid-column:1;grid-row:span 3}
 .workspace80 .seat-text73{margin-top:4px!important}
 .workspace80 .table-settings73{grid-column:1;grid-row:span 3}
 .workspace80 .desk-inspector80>.group{grid-column:2}
 .workspace80 .appearance-top78 .chairs-inline77>div{flex-wrap:nowrap!important}
 .workspace80 .appearance-top78 .chairs-inline77{width:100%}
}
@media(max-width:1049px){
 .excel-shell61.app.workspace71.workspace78.workspace80:not(.right-collapsed){grid-template-columns:120px minmax(0,1fr) var(--inspector80)!important}
 .workspace80 .system-area61>strong{font-size:14px}
 .workspace80 .ribbon-divider78{display:none}
}
/* This must outrank every display:flex/grid rule, including empty common. */
.excel-shell61.app.workspace80 .ribbon-panels58>[role=tabpanel][hidden],
.excel-shell61.app.workspace80 #ribbon-panel-common.common78.empty-common79[hidden],
.excel-shell61.app.workspace80 #ribbon-panel-common.common78[hidden],
.excel-shell61.app.workspace80 #ribbon-panel-layout.layout78[hidden],
.excel-shell61.app.workspace80 #ribbon-panel-view.view78[hidden],
.excel-shell61.app.workspace80 [data-right-pane][hidden]{display:none!important}
@media print{.excel-shell61.app.workspace80>.right{display:none!important}.excel-shell61.app.workspace80 .workspace{padding:0!important}.excel-shell61.app.workspace80 .canvas-shell{margin:0!important}}
