/* Experiment variants + the lab bar. TEST ONLY — the bar renders solely when
   the lab flag is on, and every experiment's first variant is current
   behaviour, so with the lab off this file changes nothing. */

/* Variants for whatever is currently being tested go here.
   Text size, contrast and layout moved to real preferences in
   theme.css once they stopped being open questions. */

/* ================= lab bar ================= */

#lab-bar {
  position: fixed; top: 0; left: 0; right: 0; z-index: 9999;
  background: #14100d; color: #f3ece4; font-size: 12px;
  font-family: -apple-system, BlinkMacSystemFont, system-ui, sans-serif;
  box-shadow: 0 6px 24px rgba(0,0,0,.35); max-height: 70vh; overflow-y: auto;
}
#lab-bar .lab-head {
  display: flex; align-items: center; gap: 9px; padding: 9px 12px;
  border-bottom: 1px solid #2f2820; position: sticky; top: 0; background: #14100d;
}
#lab-bar .lab-head b {
  background: #D8342A; color: #fff; border-radius: 4px;
  padding: 2px 7px; font-size: 10.5px; letter-spacing: .1em;
}
#lab-bar .lab-head span { color: #9b9086; font-size: 11.5px; }
#lab-bar .lab-x {
  margin-left: auto; background: none; border: none; color: #9b9086; font-size: 15px;
}
#lab-bar.collapsed .lab-body { display: none; }
#lab-bar.collapsed .lab-x { transform: rotate(180deg); }

#lab-bar .lab-body { padding: 4px 12px 12px; }
#lab-bar .lab-exp { padding: 9px 0; border-bottom: 1px solid #241e18; }
#lab-bar .lab-exp label { display: block; font-weight: 700; margin-bottom: 5px; }
#lab-bar .lab-exp em {
  display: block; font-style: normal; font-weight: 400;
  color: #9b9086; font-size: 11px; margin-top: 2px;
}
#lab-bar .lab-seg { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 7px; }
#lab-bar .lab-seg button {
  background: #241e18; border: 1px solid #3a322a; color: #cdc3b8;
  border-radius: 7px; padding: 7px 11px; font-size: 12px;
}
#lab-bar .lab-seg button.on { background: #FFCF31; border-color: #FFCF31; color: #14100d; font-weight: 700; }
#lab-bar .lab-foot { display: flex; align-items: center; gap: 9px; padding-top: 10px; }
#lab-bar .lab-foot code { flex: 1; color: #9b9086; font-size: 10.5px; word-break: break-all; }
#lab-bar .lab-copy {
  background: #2f2820; border: 1px solid #3a322a; color: #f3ece4;
  border-radius: 7px; padding: 6px 12px; font-size: 11.5px;
}

/* Push the app down so the bar never covers the header. */
:root:has(#lab-bar) #app { padding-top: 56px; }
