/* Scoped original-composer additions. Existing v69 geometry remains authoritative. */
.unified-work-card{container-type:inline-size;min-width:0}
.unified-work-card>.teeth-wrap,.unified-work-card>.card-body,.unified-work-card .teeth,.unified-work-card .service-row,.unified-work-card .service-followup,.unified-work-card .tech-assignment-builder{min-width:0;max-width:100%;box-sizing:border-box}
/* v69 fixed 31px tooth minima required 751px before panel padding. Keep both
   complete arches and the original connectors, allowing tooth tracks to fit. */
.unified-work-card .tooth-arch{grid-template-columns:repeat(15,minmax(0,1fr) 11px) minmax(0,1fr)!important;min-width:0;width:100%}
.unified-work-card .tooth{min-width:0;padding-inline:0}
.unified-work-card .service-row>*{min-width:0;max-width:100%}
.unified-work-card .tech-action-row{flex-wrap:wrap}
@container(max-width:760px){
  .unified-work-card .tooth-arch{grid-template-columns:repeat(15,minmax(0,1fr) 8px) minmax(0,1fr)!important;gap:2px!important}
  .unified-work-card .bridge-connector{width:8px!important}
  .unified-work-card .service-row{grid-template-columns:repeat(2,minmax(0,1fr))!important}
  .unified-work-card .service-row .add-work{grid-column:1/-1}
  .unified-work-card .service-followup{grid-template-columns:minmax(0,1fr)!important}
  .unified-work-card .tech-assignment-builder{grid-column:1/-1;grid-template-columns:repeat(2,minmax(0,1fr))!important}
}
.recovery-work-extra{display:flex;align-items:end;gap:12px;margin-top:10px}.recovery-work-extra>label{display:grid;gap:4px;max-width:180px}.recovery-work-extra [hidden]{display:none!important}.recovery-work-extra .control{height:36px}
#shadeMenu{max-height:min(410px,60vh);overflow:auto;width:320px;max-width:calc(100vw - 32px)}#shadeSearchRecovery{width:100%;margin-bottom:8px}#shadeOptions .recovery-shade-group{grid-column:1/-1;display:grid;gap:6px;margin-top:6px}#shadeOptions .recovery-shade-group>div{display:flex;flex-wrap:wrap;gap:5px}#shadeOptions .recovery-shade-group small{color:var(--muted)}#shadeMenu .option-add-row{position:sticky;bottom:0;background:var(--panel,#202328);padding-top:8px}body[data-theme=light] #shadeMenu .option-add-row{background:#fffdf9}
#workSearchRecovery{margin-bottom:8px;width:100%}.quantity-work{opacity:.45}.recovery-position-open .modal{width:min(820px,calc(100vw - 28px))!important}.recovery-position-editor{display:grid;gap:14px}.recovery-position-editor .position-scope{display:flex;flex-wrap:wrap;gap:6px}.recovery-position-editor .position-scope button{display:grid;gap:4px;min-width:70px}.recovery-position-editor small{font-size:10px;color:var(--muted)}.recovery-role-choices{display:flex;flex-wrap:wrap;gap:6px}.recovery-role-choices button,.recovery-position-editor .position-scope button{border:1px solid var(--line);border-radius:7px;padding:8px 12px;background:var(--panel,#202328);color:var(--text)}.recovery-role-choices button.on,.recovery-position-editor .position-scope button.on{border-color:var(--gold);color:var(--gold);background:rgba(215,181,109,.09)}.recovery-implant-fields,.recovery-position-grid{display:grid;grid-template-columns:1fr 1fr;gap:12px}.recovery-position-editor label{display:grid;gap:5px;color:var(--text);font-size:12px}.recovery-position-editor .wide{grid-column:1/-1}.recovery-position-editor .recovery-check{display:flex;align-items:center;gap:8px}.recovery-position-editor .control{width:100%;min-width:0}.recovery-position-editor details{padding:10px 0;border-top:1px solid var(--line)}.recovery-position-editor summary{cursor:pointer;color:var(--gold);margin-bottom:10px}.recovery-position-editor .position-param-actions{position:sticky;bottom:0;padding-top:12px;background:var(--panel,#202328)}.recovery-position-error{margin:0;color:#da8b85;min-height:1em}.recovery-production-fields .recovery-position-grid{max-height:280px;overflow:auto}.recovery-pricing-fields p,.position-role-note{color:var(--muted);font-size:12px}.recovery-position-editor input[type=checkbox]{accent-color:var(--gold)}
#teeth .tooth.implant-supported{border-color:#bd5c56!important;position:relative}#teeth .recovery-implant-mark{position:absolute;left:2px;bottom:2px;width:15px;height:25px;color:#bda4df;pointer-events:none}#teeth .recovery-abutment-shape{fill:#bd5c56;stroke:#bd5c56;stroke-width:1}#teeth .tooth.work-standard{box-shadow:inset 0 -3px #d3b060}#teeth .tooth.work-ceramic{box-shadow:inset 0 -3px #bda4df}#teeth .tooth.work-metal{box-shadow:inset 0 -3px #9a9a9a}
body[data-theme=light] .recovery-position-editor .position-param-actions{background:#fffdf9}body[data-theme=light] .recovery-role-choices button,body[data-theme=light] .recovery-position-editor .position-scope button{background:#fffdf9;color:#333}body[data-theme=light] .recovery-role-choices button.on,body[data-theme=light] .recovery-position-editor .position-scope button.on{background:#f5ecdc;color:#684e25}@media(max-width:600px){.recovery-position-grid,.recovery-implant-fields{grid-template-columns:1fr}.recovery-position-editor .wide{grid-column:auto}.recovery-role-choices button{flex:1 0 42%}}

/* Context catalog editor uses the existing theme, without replacing the work form. */
.position-reference-editor{border:1px solid var(--gold);border-radius:8px;padding:12px;background:var(--panel,#202328)}
.position-reference-editor p,.position-reference-shortcuts{font-size:12px;color:var(--muted)}
.position-reference-actions,.position-reference-shortcuts{display:flex;flex-wrap:wrap;align-items:center;gap:8px}
.position-reference-actions button,.position-reference-shortcuts button{padding:8px 12px;border:1px solid var(--line);border-radius:6px;background:var(--panel,#202328);color:var(--text)}
.position-reference-actions .work-save{border-color:var(--gold);color:var(--gold)}
.position-reference-shortcuts{margin-top:12px}.position-reference-shortcuts small{flex-basis:100%}
body[data-theme=light] .position-reference-editor,body[data-theme=light] .position-reference-actions button,body[data-theme=light] .position-reference-shortcuts button{background:#fffdf9}
