/* Smaller outlined controls leave more space for the anatomical model. */
@media(min-width:801px){
 html[data-page=atlas]:not([data-workbench-panel-closed]):not([data-atlas-focus="1"]) #appShell{grid-template-columns:minmax(0,1fr) 222px!important}
 html[data-page=atlas] #appShell{padding-right:84px!important}
 #workbenchRail{width:84px}
 #workbenchRail [data-workbench]{width:100%;min-width:0;min-height:62px;height:auto;padding:10px 6px;gap:6px;font-size:9px}
 #workbenchRail [data-workbench] svg{width:19px;height:19px}
 html[data-page=atlas] #inspector #tab-motion{padding:19px 16px!important}
 #focusedStageControls #quickTestPanel{width:188px!important}
 #viewport #scienceStageHead{right:225px!important}
 html[data-page=atlas] #viewport #studioTension{width:124px!important;padding:10px 12px!important;bottom:151px!important}
 #studioTension .studioTensionNumber output{font-size:33px!important}
 #studioTension .studioTensionNumber>span{font-size:17px}
}
@media(min-width:801px) and (max-width:1100px){
 html[data-page=atlas]:not([data-workbench-panel-closed]):not([data-atlas-focus="1"]) #appShell{grid-template-columns:minmax(0,1fr) 195px!important}
}
/* The layer controls expand inside the right navigation rail, below Capas. */
#workbenchRail{overflow-y:auto;scrollbar-width:thin}
#workbenchRail>[data-workbench]>span{max-width:100%;white-space:normal;overflow-wrap:anywhere;text-align:center}
#workbenchRail #workbenchLayers[hidden]{display:none!important}
#workbenchRail #workbenchLayers{position:static;inset:auto;width:100%;height:auto;min-height:0;flex:none;display:flex;flex-direction:column;align-items:center;gap:14px;padding:4px 0 14px;border:0;background:transparent;overflow:visible}
#workbenchRail #workbenchLayers .workbenchLayerTitle{display:none}
#workbenchRail #workbenchLayers .workbenchLayer{position:relative;flex:0 0 32px;min-width:32px;width:32px;min-height:32px;height:32px;padding:0;gap:0;border-radius:50%;border:1px solid #758a9780;background:transparent!important;box-shadow:none;color:#bccbd4}
#workbenchRail #workbenchLayers .workbenchLayer svg{width:13px;height:15px}
#workbenchRail #workbenchLayers .workbenchLayer>span{position:absolute;top:calc(100% + 2px);left:50%;transform:translateX(-50%);font-size:8px;line-height:10px;white-space:nowrap}
#workbenchRail #workbenchLayers .workbenchLayer>small{display:none}
#workbenchRail #workbenchLayers .workbenchLayer[aria-pressed=true]{border-color:#73c8ba;color:#b0e3d6;background:transparent!important}
#workbenchRail #workbenchLayers .workbenchLayer:hover:not(:disabled){border-color:#b1e9dd;background:transparent!important}
#workbenchRail #workbenchLayers .workbenchLayer:focus-visible{outline:2px solid #a5e5d5;outline-offset:2px}
html[data-page=atlas] #viewport>#motionDock{bottom:18px!important}
@media(max-width:800px){
 #workbenchRail{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));height:auto;min-height:64px;overflow:visible}
 #workbenchRail>[data-workbench]{width:100%;min-width:0;min-height:64px}
 #workbenchRail #workbenchLayers{grid-column:1/-1;grid-row:2;flex-direction:row;justify-content:center;gap:24px;padding:8px 0 18px;order:7}
 html[data-page=atlas] #viewport #studioTension{width:110px!important;padding:9px!important;bottom:105px!important}
 #studioTension .studioTensionNumber output{font-size:30px!important}
}

/* Workspace navigation mirrors the right rail, arranged horizontally. */
html[data-page=atlas] #viewport #atlasModeBar{top:80px!important;left:22px!important;right:auto!important;width:max-content!important;max-width:calc(100% - 44px);gap:0!important;align-items:stretch;background:#141c25;border:1px solid #303b47;border-radius:0;padding:0;overflow:visible}
html[data-page=atlas] #viewport #atlasModeBar button{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:5px!important;min-width:66px;min-height:50px;height:50px;padding:7px 11px!important;border:0!important;border-bottom:2px solid transparent!important;border-radius:0!important;background:transparent!important;color:#a4afbb!important;font-size:10px!important;line-height:1.2;box-shadow:none}
html[data-page=atlas] #viewport #atlasModeBar button svg{width:18px;height:18px;fill:none;stroke:currentColor;stroke-width:1.2;stroke-linecap:round;stroke-linejoin:round}
html[data-page=atlas] #viewport #atlasModeBar button.on{background:#23343a!important;color:#73c8ba!important;border-bottom-color:#73c8ba!important}
html[data-page=atlas] #viewport #atlasModeBar button::after{display:none!important}
html[data-page=atlas] #viewport #atlasModeBar button:hover:not(:disabled){background:#24303c!important;color:#e9edf1!important}
html[data-page=atlas] #viewport #atlasModeBar button:focus-visible{outline:2px solid #73c8ba;outline-offset:-4px}
@media(max-width:800px){
 html[data-page=atlas] #viewport #atlasModeBar{top:75px!important;left:12px!important;right:12px!important;width:auto!important;max-width:none}
 html[data-page=atlas] #viewport #atlasModeBar button{flex:1;min-width:0;padding:6px 3px!important;font-size:9px!important}
}

/* Tests open from their horizontal toolbar button; native select remains the event source. */
html[data-page=atlas] [data-compact-test-picker],html[data-page=atlas] #workbenchRail [data-workbench=tests]{display:none!important}
.ndSelectMenu[data-nd-source=testSelect]{background:#141c25;border-color:#303b47;border-radius:0;max-width:calc(100vw - 24px)}

html[data-page=atlas] #viewport>#toast{top:auto!important;bottom:110px!important;left:22px!important;right:auto!important;height:auto!important;width:max-content;max-width:calc(100% - 44px)!important;padding:9px 12px;transform:none!important}
/* Two synchronized anatomical examples, with independently adjustable ROM. */
.atlasWorkspace-tecnicas .tecViews{height:min(48vh,460px);min-height:340px;background:#10171f;border:1px solid #303b47;border-radius:4px}
.atlasWorkspace-tecnicas .tecView{border-color:#303b47}
.atlasWorkspace-tecnicas .tecTag{background:#141c25e8;color:#e9edf1;border:1px solid #303b47;padding:10px 14px;border-radius:3px}
.atlasWorkspace-tecnicas .tecTag b{font-size:17px}.atlasWorkspace-tecnicas .tecTag small{display:block;margin-top:4px;color:#a4afbb;font-size:11px}
.atlasWorkspace-tecnicas [data-variant=slider] .tecTag{border-left:3px solid #73c8ba}.atlasWorkspace-tecnicas [data-variant=tensioner] .tecTag{border-left:3px solid #edb66a}
.tecExamples{display:flex;gap:8px;margin-bottom:14px}.tecExamples button{border:1px solid #303b47;border-radius:4px;padding:10px 18px;background:#141c25;color:#a4afbb;font:inherit;cursor:pointer}.tecExamples button[aria-pressed=true]{border-color:#73c8ba;color:#73c8ba;background:#23343a}
.atlasWorkspace-tecnicas .tecTop>label,.atlasWorkspace-tecnicas .tecLegend,.atlasWorkspace-tecnicas .tecCharts,.atlasWorkspace-tecnicas .tecLive{display:none}
#tecHumanStatus{position:absolute;inset:0;display:flex;align-items:center;justify-content:center;background:#10171fec;color:#e9edf1;z-index:3}#tecHumanStatus[hidden]{display:none}
.tecRomPanels{display:grid;grid-template-columns:1fr 1fr;gap:12px}.tecRomPanels article{padding:14px 18px;border:1px solid #303b47;border-radius:4px;background:#141c25;color:#e9edf1}.tecRomPanels label{display:grid;grid-template-columns:1fr auto;gap:8px;font-size:12px}.tecRomPanels input{grid-column:1/-1;width:100%;accent-color:#73c8ba}.tecRomPanels [data-variant=tensioner] input{accent-color:#edb66a}
.tecRomJoint{display:grid;grid-template-columns:1fr auto;gap:4px;margin-top:14px;font-size:12px}.tecRomJoint strong{font-size:23px;color:#73c8ba;font-variant-numeric:tabular-nums}.tecRomPanels [data-variant=tensioner] strong{color:#edb66a}.tecRomJoint meter,.tecRomJoint small{grid-column:1/-1;width:100%}.tecRomJoint small{color:#a4afbb;font-size:10px}
@media(max-width:720px){.tecRomPanels{grid-template-columns:1fr}.atlasWorkspace-tecnicas .tecViews{min-height:420px;height:55vh}.tecExamples button{flex:1;padding:9px 8px;font-size:12px}}

.tecAngleOverlay{position:absolute;bottom:8px;left:12px;right:12px;margin:0;padding:8px;background:#10171fe6;border:1px solid #303b47;border-radius:4px;font-size:12px;text-align:center;color:#e8ecef}
.atlasWorkspace-tecnicas .tecTransport{margin:10px 0;gap:8px}
