/* Lab brand layer, loaded last: orange #FF8A1F for primary actions, active
   controls, selection and focus. Physical/semantic colours (body colours,
   velocity violet, gravity orange arrows, field ramps) are left untouched.
   The space scene is intentionally dark-only (color-scheme: dark). */
:root{--lab-orange:#ff8a1f;--lab-orange-soft:#ff8a1f24;--lab-orange-line:#ff8a1f8c;--lab-on-orange:#1c0e02}

/* Focus: one visible orange ring everywhere. */
#app :focus-visible,dialog :focus-visible{outline:2px solid var(--lab-orange)!important;outline-offset:2px}
input[type=range],input[type=checkbox],input[type=radio]{accent-color:var(--lab-orange)}

/* Primary actions: orange surface with dark text (contrast ≈ 8:1). */
.uni-button.uni-primary,.btn.hi,#learnPlay,.experiment-launch{background:var(--lab-orange)!important;border-color:var(--lab-orange)!important;color:var(--lab-on-orange)!important;font-weight:650}
.uni-button.uni-primary:hover,.btn.hi:hover,#learnPlay:hover,.experiment-launch:hover{background:#ffa04a!important;border-color:#ffa04a!important}
#uniPlay{border-color:var(--lab-orange-line);color:#ffe2c6}
#uniPlay:hover{background:#3a2412}

/* Active / selected controls: orange edge on the existing dark surface. */
nav button.on,.seg button.on,.chips button.on,.tool[aria-pressed="true"],
#warpCamera[aria-expanded=true],.cam-segments button[aria-pressed=true],
#learnExperiments button[aria-pressed=true],.learn-tabs button[aria-expanded=true],#learnAnswers button[aria-pressed=true],
.scene-dock button[aria-pressed="true"],.uni-view-chips button[aria-pressed=true],.uni-body[aria-pressed=true],
.uni-workbench-tabs button[aria-expanded=true]{
  border-color:var(--lab-orange-line)!important;background:#2a1d14!important;color:#fff1e3!important;
  box-shadow:inset 0 -2px 0 var(--lab-orange)!important}
nav button.on small,.uni-workbench-tabs button[aria-expanded=true]>span,#learnExperiments button[aria-pressed=true]>span{color:var(--lab-orange)!important}

/* Mission progress and completion use the brand colour. */
.prog i{background:var(--lab-orange)!important}
#tMissions .badge{background:var(--lab-orange)!important;color:var(--lab-on-orange)!important}
#mList li.done .ck{border-color:var(--lab-orange)!important;background:var(--lab-orange)!important;color:var(--lab-on-orange)!important}

/* Fun-fact card: in the sandbox the bottom-right corner holds the playback dock,
   so on wide screens the card sits under the toolbar instead of over the controls. */
@media (min-width:901px) and (min-height:521px){
  body.universe-mode #fact{top:62px;bottom:auto;max-height:calc(100% - 300px)}
}
