/* Shared material selector only. Never restyle the canvas, camera or parameter panels. */
html[data-gray-materials-portal] body #reference-material-dock {position:fixed!important;bottom:20px!important;z-index:2500!important;}
html[data-gray-materials][data-gray-materials][data-gray-materials] body #reference-material-dock,
html[data-gray-materials][data-gray-materials][data-gray-materials] body #reference-material-dock .reference-dock-spheres {display:flex!important;flex-wrap:nowrap!important;background:transparent!important;border:0!important;border-radius:0!important;box-shadow:none!important;outline:0!important;backdrop-filter:none!important;overflow:visible!important;box-sizing:border-box!important;min-width:0!important;}
html[data-gray-materials][data-gray-materials][data-gray-materials] body #reference-material-dock {left:50%!important;right:auto!important;transform:translateX(-50%)!important;width:max-content!important;max-width:calc(100% - 24px)!important;padding:4px!important;gap:0!important;}
html[data-gray-materials][data-gray-materials][data-gray-materials] body #reference-material-dock .reference-dock-spheres {width:auto!important;max-width:none!important;padding:0!important;gap:8px!important;}
html[data-gray-materials][data-gray-materials][data-gray-materials] body #reference-material-dock .reference-sphere {width:34px!important;height:34px!important;min-width:0!important;padding:2px!important;border:1px solid transparent!important;border-radius:50%!important;box-sizing:border-box!important;flex:0 0 auto!important;}
html[data-gray-materials][data-gray-materials][data-gray-materials] body #reference-material-dock .reference-sphere[aria-pressed="true"] {border-color:#c9ab67!important;outline:1px solid #c9ab67!important;outline-offset:1px!important;}
html[data-gray-materials][data-gray-materials][data-gray-materials] body #reference-material-dock::before,html[data-gray-materials][data-gray-materials][data-gray-materials] body #reference-material-dock::after,
html[data-gray-materials][data-gray-materials][data-gray-materials] body #reference-material-dock .reference-dock-spheres::before,html[data-gray-materials][data-gray-materials][data-gray-materials] body #reference-material-dock .reference-dock-spheres::after {display:none!important;}
html[data-gray-materials][data-gray-materials][data-gray-materials] body #reference-material-dock .reference-dock-title {display:none!important;}
html[data-gray-materials][data-gray-materials][data-gray-materials] body #reference-material-dock .reference-sphere[data-p74-disabled="true"] {opacity:.48!important;cursor:not-allowed!important;}
html[data-gray-materials][data-gray-materials][data-gray-materials] #p74-original-status {position:absolute;bottom:100px;left:50%;transform:translateX(-50%);max-width:calc(100% - 40px);padding:8px 12px;background:#252524;color:#f0eee7;border:1px solid #4a4947;border-radius:8px;font:13px/1.5 system-ui,sans-serif;z-index:150;pointer-events:none;}
html[data-gray-materials][data-gray-materials][data-gray-materials] #p74-original-status[hidden] {display:none!important;}
@media(max-width:560px){
 html[data-gray-materials-portal] body #reference-material-dock {bottom:80px!important;}
 html[data-gray-materials][data-gray-materials][data-gray-materials][data-gray-materials][data-gray-materials] body #reference-material-dock .reference-dock-spheres {gap:2px!important;}
 html[data-gray-materials][data-gray-materials][data-gray-materials][data-gray-materials][data-gray-materials] body #reference-material-dock .reference-sphere {width:clamp(28px,7.7vw,40px)!important;height:clamp(28px,7.7vw,40px)!important;}
}

/* Static eight slots stay hidden until real thumbnails have decoded. */
html[data-gray-materials] body #reference-material-dock[data-gray-dock-state="loading"] {visibility:hidden!important;pointer-events:none!important;}
html[data-gray-materials] #gray-material-loading {position:fixed;bottom:24px;left:50%;transform:translateX(-50%);z-index:2600;color:#dcc58d;font:13px/1.5 system-ui,sans-serif;pointer-events:none;}
html[data-gray-materials] #gray-material-loading[hidden] {display:none!important;}
html[data-gray-materials][data-gray-materials][data-gray-materials] body #reference-material-dock .reference-sphere {background:none!important;box-shadow:none!important;}
html[data-gray-materials] body #reference-material-dock .reference-sphere::before,html[data-gray-materials] body #reference-material-dock .reference-sphere::after {display:none!important;}
@media(max-width:560px){html[data-gray-materials] #gray-material-loading{bottom:84px;}}
