:root {
  color-scheme: light;
  --lab-ink: #18322a;
  --lab-muted: #60716b;
  --lab-faint: #8c9a95;
  --lab-canvas: #f6f8f6;
  --lab-panel: #ffffff;
  --lab-panel-soft: #f8faf7;
  --lab-line: #dfe6e1;
  --lab-line-strong: #cbd7d0;
  --lab-green-950: #103629;
  --lab-green-900: #123e31;
  --lab-green-800: #18543e;
  --lab-green-700: #1f704d;
  --lab-green-600: #27845b;
  --lab-green-100: #e1f1e7;
  --lab-green-50: #f0f8f3;
  --lab-amber: #9b641d;
  --lab-amber-soft: #fff3d9;
  --lab-red: #a54239;
  --lab-red-soft: #fceae7;
  --lab-blue: #366b85;
  --lab-blue-soft: #e7f2f7;
  --lab-shadow-sm: 0 1px 2px rgba(20, 47, 38, 0.05);
  --lab-shadow-md: 0 14px 40px rgba(20, 47, 38, 0.1);
  --lab-radius-sm: 8px;
  --lab-radius: 10px;
  --lab-radius-lg: 14px;
  --lab-sidebar: 284px;
  font-family:
    system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
    "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Helvetica Neue", sans-serif;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
}

* {
  box-sizing: border-box;
}

html,
body {
  min-height: 100%;
  margin: 0;
}

body {
  background: var(--lab-canvas);
  color: var(--lab-ink);
  font-size: 15px;
  line-height: 1.55;
}

button,
input,
textarea,
select {
  font: inherit;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

button {
  color: inherit;
}

a {
  color: inherit;
  text-decoration: none;
}

svg {
  display: block;
}

.lab-icon {
  width: 18px;
  height: 18px;
  flex: 0 0 auto;
  stroke: currentColor;
  stroke-width: 1.8;
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.lab-boot {
  min-height: 100vh;
  display: grid;
  place-content: center;
  justify-items: center;
  gap: 14px;
  color: var(--lab-muted);
}

.lab-boot-mark,
.lab-brand-mark {
  display: grid;
  place-items: center;
  background: var(--lab-green-900);
  color: #fff;
  font-weight: 750;
  letter-spacing: -0.04em;
}

.lab-boot-mark {
  width: 48px;
  height: 48px;
  border-radius: 15px;
  box-shadow: 0 10px 30px rgba(18, 62, 49, 0.2);
}

.lab-shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: var(--lab-sidebar) minmax(0, 1fr);
}

.lab-sidebar {
  position: sticky;
  top: 0;
  height: 100vh;
  min-height: 0;
  display: flex;
  flex-direction: column;
  background: var(--lab-green-950);
  color: #dcebe2;
  border-right: 1px solid rgba(255, 255, 255, 0.05);
  z-index: 20;
}

.lab-brand {
  height: 74px;
  padding: 0 20px;
  display: flex;
  align-items: center;
  gap: 11px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.lab-brand-mark {
  width: 34px;
  height: 34px;
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.1);
}

.lab-brand-copy {
  min-width: 0;
  display: grid;
  line-height: 1.18;
}

.lab-brand-copy strong {
  color: #fff;
  font-size: 15px;
  letter-spacing: 0.01em;
}

.lab-brand-copy small {
  margin-top: 3px;
  color: #94ada1;
  font-size: 11px;
}

.lab-sidebar-primary {
  margin: 16px 14px 10px;
  width: calc(100% - 28px);
}

.lab-sidebar-scroll {
  min-height: 0;
  flex: 1;
  overflow: auto;
  overscroll-behavior: contain;
  padding: 4px 10px 18px;
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, 0.16) transparent;
}

.lab-nav-link,
.lab-project-link,
.lab-module-link {
  width: 100%;
  min-height: 42px;
  display: flex;
  align-items: center;
  gap: 10px;
  border: 0;
  border-radius: 10px;
  background: transparent;
  color: #b8cbc1;
  cursor: pointer;
  text-align: left;
}

.lab-nav-link,
.lab-module-link {
  padding: 0 12px;
}

.lab-nav-link {
  font: inherit;
}

.lab-nav-link:hover,
.lab-project-link:hover,
.lab-module-link:hover {
  background: rgba(255, 255, 255, 0.07);
  color: #fff;
}

.lab-nav-link.is-active,
.lab-project-link.is-active {
  background: rgba(133, 206, 161, 0.14);
  color: #effff4;
}

.lab-sidebar-label {
  margin: 22px 11px 8px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: #789489;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.lab-project-link {
  position: relative;
  min-height: 48px;
  padding: 7px 10px;
  align-items: flex-start;
}

.lab-project-dot {
  width: 8px;
  height: 8px;
  margin-top: 8px;
  border-radius: 999px;
  background: #61b981;
  box-shadow: 0 0 0 3px rgba(97, 185, 129, 0.1);
}

.lab-project-dot.is-paused {
  background: #d0a35f;
}

.lab-project-dot.is-completed,
.lab-project-dot.is-archived {
  background: #778b82;
}

.lab-project-link-copy {
  min-width: 0;
  display: grid;
}

.lab-project-link-copy strong,
.lab-project-link-copy small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.lab-project-link-copy strong {
  color: inherit;
  font-size: 13px;
  font-weight: 620;
}

.lab-project-link-copy small {
  color: #7f998d;
  font-size: 11px;
}

.lab-sidebar-footer {
  padding: 12px 14px 14px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.lab-product-nav {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 0 7px 10px;
}

.lab-product-nav a {
  color: #9bb1a6;
  font-size: 12px;
  font-weight: 650;
}

.lab-product-nav a:hover,
.lab-product-nav a:focus-visible {
  color: #fff;
  outline: none;
}

.lab-module-link {
  margin-bottom: 8px;
  font-size: 13px;
}

.lab-user {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 7px 4px;
}

.lab-avatar {
  width: 32px;
  height: 32px;
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: #d9eee1;
  color: var(--lab-green-900);
  font-size: 12px;
  font-weight: 750;
}

.lab-user-copy {
  min-width: 0;
  flex: 1;
  display: grid;
  line-height: 1.25;
}

.lab-user-copy strong,
.lab-user-copy small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.lab-user-copy strong {
  color: #eef8f1;
  font-size: 12px;
}

.lab-user-copy small {
  color: #7e9a8d;
  font-size: 10px;
}

.lab-main {
  min-width: 0;
}

.lab-topbar {
  position: sticky;
  top: 0;
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 0 28px;
  background: rgba(244, 246, 242, 0.92);
  border-bottom: 1px solid rgba(203, 215, 208, 0.75);
  backdrop-filter: blur(12px);
  z-index: 15;
}

.lab-mobile-menu {
  display: none;
}

.lab-breadcrumbs {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 7px;
  color: var(--lab-muted);
  font-size: 13px;
}

.lab-breadcrumbs a:hover {
  color: var(--lab-green-700);
}

.lab-breadcrumbs strong {
  max-width: min(48vw, 520px);
  overflow: hidden;
  text-overflow: ellipsis;
  color: var(--lab-ink);
  white-space: nowrap;
}

.lab-content {
  width: min(1220px, 100%);
  margin: 0 auto;
  padding: 38px clamp(24px, 4vw, 56px) 80px;
}

.lab-content.is-run {
  width: min(980px, 100%);
}

.lab-button {
  min-height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 0 15px;
  border: 1px solid transparent;
  border-radius: 10px;
  background: transparent;
  color: var(--lab-ink);
  font-size: 13px;
  font-weight: 650;
  cursor: pointer;
  transition:
    transform 120ms ease,
    border-color 120ms ease,
    background 120ms ease,
    box-shadow 120ms ease;
}

button.lab-mobile-menu {
  display: none;
}

.lab-button:hover:not(:disabled) {
  transform: translateY(-1px);
}

.lab-button:disabled {
  opacity: 0.52;
  cursor: not-allowed;
}

.lab-button.is-primary {
  background: var(--lab-green-700);
  color: #fff;
  box-shadow: 0 5px 14px rgba(31, 112, 77, 0.16);
}

.lab-button.is-primary:hover:not(:disabled) {
  background: var(--lab-green-800);
}

.lab-button.is-light {
  border-color: var(--lab-line-strong);
  background: var(--lab-panel);
  box-shadow: var(--lab-shadow-sm);
}

.lab-button.is-light:hover:not(:disabled) {
  border-color: #a8bcb0;
  background: #fff;
}

.lab-button.is-quiet {
  color: var(--lab-muted);
}

.lab-button.is-danger {
  border-color: #e8c8c3;
  background: #fff;
  color: var(--lab-red);
}

.lab-button.is-small {
  min-height: 34px;
  padding: 0 11px;
  border-radius: 9px;
  font-size: 12px;
}

.lab-button.is-icon {
  width: 38px;
  padding: 0;
}

.lab-sidebar .lab-button.is-primary {
  background: #dff3e6;
  color: var(--lab-green-950);
  box-shadow: none;
}

.lab-sidebar .lab-button.is-primary:hover:not(:disabled) {
  background: #effaf3;
}

button:focus-visible,
a:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible,
[tabindex]:focus-visible {
  outline: 3px solid rgba(39, 132, 91, 0.24);
  outline-offset: 2px;
}

.lab-page-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 28px;
}

.lab-page-title {
  min-width: 0;
}

.lab-eyebrow {
  margin: 0 0 7px;
  color: var(--lab-green-700);
  font-size: 11px;
  font-weight: 760;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}

.lab-page-title h1 {
  margin: 0;
  color: var(--lab-green-950);
  font-size: clamp(27px, 3vw, 40px);
  font-weight: 720;
  letter-spacing: -0.035em;
  line-height: 1.12;
}

.lab-page-title > p:not(.lab-eyebrow) {
  max-width: 760px;
  margin: 11px 0 0;
  color: var(--lab-muted);
  font-size: 15px;
}

.lab-page-actions {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  gap: 8px;
}

.lab-dashboard-head {
  min-height: 96px;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  padding-bottom: 23px;
  border-bottom: 1px solid var(--lab-line);
}

.lab-dashboard-head h1 {
  margin: 7px 0 0;
  color: var(--lab-green-950);
  font-size: clamp(34px, 4vw, 48px);
  font-weight: 700;
  letter-spacing: -0.045em;
  line-height: 1;
}

.lab-dashboard-head > div > p:last-child {
  margin: 12px 0 0;
  color: var(--lab-muted);
  font-size: 13px;
}

.lab-section {
  margin-top: 34px;
}

.lab-section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 14px;
}

.lab-section-title h2,
.lab-card-head h2,
.lab-card-head h3 {
  margin: 0;
  color: var(--lab-green-950);
  font-weight: 690;
  letter-spacing: -0.02em;
}

.lab-section-title h2 {
  font-size: 19px;
}

.lab-section-title p {
  margin: 4px 0 0;
  color: var(--lab-muted);
  font-size: 12px;
}

.lab-grid {
  display: grid;
  gap: 16px;
}

.lab-grid.is-projects {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.lab-grid.is-two {
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  align-items: start;
}

.lab-card {
  border: 1px solid var(--lab-line);
  border-radius: var(--lab-radius);
  background: var(--lab-panel);
  box-shadow: var(--lab-shadow-sm);
}

.lab-card.is-interactive {
  cursor: pointer;
  transition:
    border-color 150ms ease,
    transform 150ms ease,
    box-shadow 150ms ease;
}

.lab-card.is-interactive:hover {
  border-color: #b9ccc0;
  transform: translateY(-2px);
  box-shadow: 0 10px 26px rgba(23, 61, 48, 0.08);
}

.lab-project-card {
  min-height: 238px;
  display: flex;
  flex-direction: column;
  padding: 22px;
}

.lab-project-card-head,
.lab-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
}

.lab-project-card h3 {
  margin: 0;
  color: var(--lab-green-950);
  font-size: 18px;
  font-weight: 690;
  letter-spacing: -0.02em;
}

.lab-project-goal {
  display: -webkit-box;
  overflow: hidden;
  margin: 9px 0 16px;
  color: var(--lab-muted);
  font-size: 13px;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.lab-current-line {
  margin: auto 0 16px;
  padding: 12px 13px;
  border-left: 3px solid #73b88d;
  border-radius: 0 9px 9px 0;
  background: var(--lab-green-50);
}

.lab-current-line small {
  display: block;
  margin-bottom: 3px;
  color: var(--lab-green-700);
  font-size: 10px;
  font-weight: 730;
  letter-spacing: 0.04em;
}

.lab-current-line p {
  display: -webkit-box;
  overflow: hidden;
  margin: 0;
  color: #355b48;
  font-size: 12px;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.lab-card-metrics {
  display: flex;
  align-items: center;
  gap: 15px;
  padding-top: 14px;
  border-top: 1px solid var(--lab-line);
  color: var(--lab-muted);
  font-size: 11px;
}

.lab-card-metrics span {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.lab-card-metrics .lab-icon {
  width: 14px;
  height: 14px;
}

.lab-status {
  min-height: 24px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 2px 9px;
  border-radius: 999px;
  background: var(--lab-green-100);
  color: var(--lab-green-700);
  font-size: 10px;
  font-weight: 730;
  white-space: nowrap;
}

.lab-status::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
}

.lab-status.is-draft,
.lab-status.is-planned,
.lab-status.is-unknown {
  background: #edf0ee;
  color: #6b7973;
}

.lab-status.is-paused,
.lab-status.is-in_progress,
.lab-status.is-medium {
  background: var(--lab-amber-soft);
  color: var(--lab-amber);
}

.lab-status.is-cancelled,
.lab-status.is-failed,
.lab-status.is-low {
  background: var(--lab-red-soft);
  color: var(--lab-red);
}

.lab-status.is-completed,
.lab-status.is-concluded,
.lab-status.is-answered,
.lab-status.is-high {
  background: var(--lab-blue-soft);
  color: var(--lab-blue);
}

.lab-status.is-archived,
.lab-status.is-parked {
  background: #e9ecea;
  color: #728079;
}

.lab-empty {
  min-height: 250px;
  display: grid;
  place-items: center;
  padding: 34px;
  border: 1px dashed var(--lab-line-strong);
  border-radius: var(--lab-radius);
  background: rgba(255, 255, 255, 0.48);
  text-align: center;
}

.lab-empty-illustration {
  width: 62px;
  height: 62px;
  display: grid;
  place-items: center;
  margin: 0 auto 16px;
  border-radius: 18px;
  background: var(--lab-green-100);
  color: var(--lab-green-700);
}

.lab-empty-illustration .lab-icon {
  width: 28px;
  height: 28px;
}

.lab-empty h2,
.lab-empty h3 {
  margin: 0;
  color: var(--lab-green-950);
  font-size: 17px;
}

.lab-empty p {
  max-width: 430px;
  margin: 8px auto 18px;
  color: var(--lab-muted);
  font-size: 13px;
}

.lab-project-header {
  padding: 25px 28px;
}

.lab-project-meta {
  margin-top: 18px;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 9px 16px;
  color: var(--lab-muted);
  font-size: 12px;
}

.lab-project-meta span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.lab-project-meta .lab-icon {
  width: 15px;
  height: 15px;
}

.lab-member-stack {
  display: flex;
  align-items: center;
}

.lab-member-stack .lab-avatar {
  width: 27px;
  height: 27px;
  margin-left: -6px;
  border: 2px solid var(--lab-panel);
  font-size: 9px;
}

.lab-member-stack .lab-avatar:first-child {
  margin-left: 0;
}

.lab-synthesis {
  overflow: hidden;
  margin-top: 18px;
  border-color: #c7dfd0;
  background: #fbfefc;
}

.lab-synthesis-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 17px 20px;
  border-bottom: 1px solid #dcece2;
  background: var(--lab-green-50);
}

.lab-synthesis-top strong {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--lab-green-800);
  font-size: 13px;
}

.lab-synthesis-top small {
  color: var(--lab-faint);
  font-size: 10px;
}

.lab-synthesis-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.lab-synthesis-item {
  min-height: 120px;
  padding: 19px 20px;
  border-right: 1px solid var(--lab-line);
  border-bottom: 1px solid var(--lab-line);
}

.lab-synthesis-item:nth-child(2n) {
  border-right: 0;
}

.lab-synthesis-item:nth-last-child(-n + 2) {
  border-bottom: 0;
}

.lab-synthesis-item small {
  display: block;
  margin-bottom: 7px;
  color: var(--lab-faint);
  font-size: 10px;
  font-weight: 720;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.lab-synthesis-item p {
  margin: 0;
  color: #2e483e;
  font-size: 13px;
  white-space: pre-wrap;
}

.lab-synthesis-empty {
  padding: 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.lab-synthesis-empty h3 {
  margin: 0;
  color: var(--lab-green-950);
  font-size: 16px;
}

.lab-synthesis-empty p {
  margin: 5px 0 0;
  color: var(--lab-muted);
  font-size: 12px;
}

.lab-list-card {
  overflow: hidden;
}

.lab-list-card > .lab-card-head {
  padding: 19px 20px 15px;
}

.lab-card-head h2 {
  font-size: 17px;
}

.lab-card-head h3 {
  font-size: 15px;
}

.lab-card-head p {
  margin: 4px 0 0;
  color: var(--lab-muted);
  font-size: 11px;
}

.lab-list {
  margin: 0;
  padding: 0;
  list-style: none;
  border-top: 1px solid var(--lab-line);
}

.lab-list-item {
  padding: 16px 20px;
  border-bottom: 1px solid var(--lab-line);
}

.lab-list-item:last-child {
  border-bottom: 0;
}

.lab-question {
  display: grid;
  grid-template-columns: 22px minmax(0, 1fr) auto;
  gap: 11px;
  align-items: start;
}

.lab-question-index {
  width: 22px;
  height: 22px;
  display: grid;
  place-items: center;
  margin-top: 1px;
  border-radius: 7px;
  background: var(--lab-green-100);
  color: var(--lab-green-700);
  font-size: 10px;
  font-weight: 740;
}

.lab-question-copy p {
  margin: 0;
  color: var(--lab-ink);
  font-size: 13px;
  font-weight: 580;
}

.lab-question-copy small {
  display: block;
  margin-top: 5px;
  color: var(--lab-muted);
  font-size: 11px;
}

.lab-question-actions {
  display: flex;
  align-items: center;
  gap: 6px;
}

.lab-list-empty {
  padding: 32px 22px;
  text-align: center;
  color: var(--lab-muted);
  font-size: 12px;
}

.lab-experiment-row {
  display: block;
  padding: 17px 20px;
  border-bottom: 1px solid var(--lab-line);
  transition: background 120ms ease;
}

.lab-experiment-row:last-child {
  border-bottom: 0;
}

.lab-experiment-row:hover {
  background: var(--lab-panel-soft);
}

.lab-experiment-row-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
}

.lab-experiment-row h3 {
  margin: 0;
  color: var(--lab-green-950);
  font-size: 14px;
  font-weight: 650;
}

.lab-experiment-row p {
  display: -webkit-box;
  overflow: hidden;
  margin: 6px 0 11px;
  color: var(--lab-muted);
  font-size: 12px;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.lab-experiment-row-foot {
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--lab-faint);
  font-size: 10px;
}

.lab-experiment-row-foot span {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.lab-experiment-row-foot .lab-icon {
  width: 13px;
  height: 13px;
}

.lab-science-summary {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  overflow: hidden;
  margin-bottom: 22px;
}

.lab-science-block {
  min-height: 150px;
  padding: 20px;
  border-right: 1px solid var(--lab-line);
}

.lab-science-block:last-child {
  border-right: 0;
}

.lab-science-block small {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 9px;
  color: var(--lab-green-700);
  font-size: 10px;
  font-weight: 740;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.lab-science-block p {
  margin: 0;
  color: #2d463c;
  font-size: 13px;
  white-space: pre-wrap;
}

.lab-run-list {
  display: grid;
  gap: 11px;
}

.lab-run-card {
  display: grid;
  grid-template-columns: 52px minmax(0, 1fr) auto;
  gap: 15px;
  align-items: center;
  padding: 16px 18px;
}

.lab-run-number {
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  border-radius: 13px;
  background: var(--lab-green-50);
  color: var(--lab-green-700);
  font-size: 11px;
  font-weight: 760;
}

.lab-run-copy h3 {
  margin: 0;
  color: var(--lab-green-950);
  font-size: 14px;
}

.lab-run-copy p {
  display: -webkit-box;
  overflow: hidden;
  margin: 5px 0 0;
  color: var(--lab-muted);
  font-size: 11px;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 1;
}

.lab-run-meta {
  display: flex;
  align-items: center;
  gap: 9px;
}

.lab-proof {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: var(--lab-green-700);
  font-size: 10px;
  font-weight: 700;
}

.lab-proof .lab-icon {
  width: 14px;
  height: 14px;
}

.lab-run-form {
  display: grid;
  gap: 18px;
}

.lab-run-form[hidden] {
  display: none;
}

.lab-form-section {
  overflow: hidden;
}

.lab-form-section-head {
  padding: 19px 22px 13px;
  border-bottom: 1px solid var(--lab-line);
}

.lab-form-section-head h2 {
  margin: 0;
  color: var(--lab-green-950);
  font-size: 16px;
  font-weight: 680;
}

.lab-form-section-head p {
  margin: 4px 0 0;
  color: var(--lab-muted);
  font-size: 11px;
}

.lab-form-section-body {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 17px;
  padding: 20px 22px 23px;
}

.lab-field {
  min-width: 0;
  display: grid;
  gap: 7px;
  color: var(--lab-ink);
  font-size: 12px;
  font-weight: 620;
}

.lab-field.is-wide {
  grid-column: 1 / -1;
}

.lab-field small {
  color: var(--lab-faint);
  font-size: 10px;
  font-weight: 450;
}

.lab-input,
.lab-textarea,
.lab-select {
  width: 100%;
  border: 1px solid var(--lab-line-strong);
  border-radius: 10px;
  background: #fff;
  color: var(--lab-ink);
  font-size: 13px;
  font-weight: 450;
  outline: 0;
  transition:
    border-color 120ms ease,
    box-shadow 120ms ease;
}

.lab-input,
.lab-select {
  height: 43px;
  padding: 0 12px;
}

.lab-textarea {
  min-height: 108px;
  padding: 11px 12px;
  line-height: 1.55;
  resize: vertical;
}

.lab-textarea.is-large {
  min-height: 150px;
}

.lab-input:hover,
.lab-textarea:hover,
.lab-select:hover {
  border-color: #b7c7bd;
}

.lab-input:focus,
.lab-textarea:focus,
.lab-select:focus {
  border-color: var(--lab-green-600);
  box-shadow: 0 0 0 3px rgba(39, 132, 91, 0.1);
}

.lab-input:disabled,
.lab-textarea:disabled,
.lab-select:disabled {
  background: #f3f5f3;
  color: #66746e;
}

.lab-run-actions {
  position: sticky;
  bottom: 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 12px 14px 12px 18px;
  border: 1px solid rgba(203, 215, 208, 0.9);
  border-radius: 13px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 12px 32px rgba(21, 54, 43, 0.13);
  backdrop-filter: blur(10px);
  z-index: 10;
}

.lab-save-state {
  display: flex;
  align-items: center;
  gap: 7px;
  color: var(--lab-muted);
  font-size: 11px;
}

.lab-save-state.is-dirty {
  color: var(--lab-amber);
}

.lab-save-state .lab-icon {
  width: 14px;
  height: 14px;
}

.lab-run-actions-buttons {
  display: flex;
  align-items: center;
  gap: 8px;
}

.lab-record-banner {
  display: flex;
  align-items: flex-start;
  gap: 13px;
  margin-bottom: 18px;
  padding: 15px 17px;
  border: 1px solid #c8e2d1;
  border-radius: 12px;
  background: var(--lab-green-50);
}

.lab-record-banner > .lab-icon {
  width: 20px;
  height: 20px;
  color: var(--lab-green-700);
}

.lab-record-banner strong {
  display: block;
  color: var(--lab-green-800);
  font-size: 12px;
}

.lab-record-banner p {
  margin: 4px 0 0;
  color: var(--lab-muted);
  font-size: 11px;
}

.lab-records {
  margin-top: 20px;
}

.lab-record {
  overflow: hidden;
  margin-top: 10px;
}

.lab-record summary {
  min-height: 50px;
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 0 16px;
  cursor: pointer;
  color: var(--lab-ink);
  font-size: 12px;
  font-weight: 620;
  list-style: none;
}

.lab-record summary::-webkit-details-marker {
  display: none;
}

.lab-record summary small {
  margin-left: auto;
  color: var(--lab-faint);
  font-size: 10px;
  font-weight: 450;
}

.lab-record-body {
  padding: 0 16px 16px;
  border-top: 1px solid var(--lab-line);
}

.lab-hash {
  margin: 12px 0 0;
  padding: 9px 10px;
  overflow-wrap: anywhere;
  border-radius: 8px;
  background: #f1f4f2;
  color: #65756e;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 9px;
}

.lab-history {
  display: grid;
  gap: 8px;
}

.lab-history-item {
  position: relative;
  padding: 14px 16px 14px 30px;
  border-left: 1px solid var(--lab-line-strong);
}

.lab-history-item::before {
  content: "";
  position: absolute;
  top: 20px;
  left: -5px;
  width: 9px;
  height: 9px;
  border: 2px solid var(--lab-canvas);
  border-radius: 50%;
  background: var(--lab-green-600);
}

.lab-history-item small {
  color: var(--lab-faint);
  font-size: 10px;
}

.lab-history-item p {
  margin: 5px 0 0;
  color: var(--lab-muted);
  font-size: 12px;
}

.lab-modal-backdrop {
  position: fixed;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(8, 28, 21, 0.46);
  backdrop-filter: blur(4px);
  z-index: 100;
  animation: lab-fade-in 140ms ease-out;
}

.lab-modal-backdrop > form {
  width: 100%;
  min-width: 0;
}

.lab-modal-backdrop > form > .lab-modal {
  margin-inline: auto;
}

.lab-modal {
  width: min(610px, 100%);
  max-height: min(86vh, 820px);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.35);
  border-radius: 18px;
  background: var(--lab-panel);
  box-shadow: 0 28px 80px rgba(6, 28, 20, 0.28);
  animation: lab-modal-in 180ms ease-out;
}

.lab-modal.is-wide {
  width: min(760px, 100%);
}

.lab-modal-head {
  position: sticky;
  top: 0;
  flex: 0 0 auto;
  min-height: 68px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 15px 18px 15px 22px;
  border-bottom: 1px solid var(--lab-line);
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(9px);
  z-index: 2;
}

.lab-modal-head h2 {
  margin: 0;
  color: var(--lab-green-950);
  font-size: 18px;
  font-weight: 690;
  letter-spacing: -0.02em;
}

.lab-modal-head p {
  margin: 3px 0 0;
  color: var(--lab-muted);
  font-size: 11px;
}

.lab-modal-body {
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-gutter: stable;
  padding: 22px;
}

.lab-modal-fields {
  display: grid;
  gap: 17px;
}

.lab-modal-foot {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  padding: 14px 22px 20px;
  border-top: 1px solid var(--lab-line);
  background: rgba(255, 255, 255, 0.97);
}

/* Lab onboarding mirrors Research's in-product guide while keeping the
   scientific workflow and evidence safeguards specific to this module. */
.lab-guide {
  display: grid;
  gap: 18px;
}

.lab-guide-tabs {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.lab-guide-tab {
  min-width: 0;
  min-height: 42px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 8px 10px;
  border: 1px solid var(--lab-line);
  border-radius: 10px;
  background: var(--lab-panel-soft);
  color: var(--lab-muted);
  cursor: pointer;
  font-size: 12px;
  font-weight: 650;
}

.lab-guide-tab:hover {
  border-color: var(--lab-line-strong);
  color: var(--lab-green-800);
}

.lab-guide-tab.is-selected {
  border-color: #a9c9b6;
  background: var(--lab-green-50);
  color: var(--lab-green-800);
  box-shadow: inset 0 0 0 1px rgba(39, 132, 91, 0.08);
}

.lab-guide-tab .lab-icon {
  width: 16px;
  height: 16px;
}

.lab-guide-panel {
  min-height: 370px;
}

.lab-guide-intro {
  margin: 0 0 13px;
  color: var(--lab-muted);
  font-size: 13px;
}

.lab-guide-items {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.lab-guide-item {
  min-height: 138px;
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  align-content: start;
  gap: 11px;
  padding: 15px;
  border: 1px solid var(--lab-line);
  border-radius: 12px;
  background: var(--lab-panel-soft);
}

.lab-guide-step,
.lab-guide-item-icon {
  width: 32px;
  height: 32px;
  display: grid;
  place-items: center;
  border-radius: 10px;
  background: var(--lab-green-100);
  color: var(--lab-green-700);
  font-size: 12px;
  font-weight: 760;
}

.lab-guide-item-icon .lab-icon {
  width: 17px;
  height: 17px;
}

.lab-guide-item h3 {
  margin: 1px 0 5px;
  color: var(--lab-green-950);
  font-size: 13px;
  font-weight: 690;
}

.lab-guide-item p {
  margin: 0;
  color: var(--lab-muted);
  font-size: 11px;
  line-height: 1.65;
}

.lab-guide-item.is-example {
  background: var(--lab-green-50);
  border-color: #c9ddd1;
}

.lab-guide-item.is-example p {
  color: #476159;
  white-space: pre-line;
}

.lab-guide-item.is-example:last-child:nth-child(odd) {
  grid-column: 1 / -1;
}

.lab-guide-progress {
  margin-right: auto;
  color: var(--lab-faint);
  font-size: 11px;
  font-variant-numeric: tabular-nums;
}

.lab-choice-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 9px;
}

.lab-choice {
  position: relative;
}

.lab-choice input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.lab-choice span {
  min-height: 58px;
  display: grid;
  place-content: center;
  gap: 2px;
  padding: 9px;
  border: 1px solid var(--lab-line-strong);
  border-radius: 10px;
  background: #fff;
  text-align: center;
  cursor: pointer;
}

.lab-choice span strong {
  font-size: 12px;
}

.lab-choice span small {
  color: var(--lab-muted);
  font-size: 9px;
}

.lab-choice input:checked + span {
  border-color: var(--lab-green-600);
  background: var(--lab-green-50);
  box-shadow: 0 0 0 2px rgba(39, 132, 91, 0.1);
}

.lab-members {
  display: grid;
  gap: 8px;
}

.lab-member-row {
  min-height: 58px;
  display: grid;
  grid-template-columns: 36px minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  padding: 8px 10px;
  border: 1px solid var(--lab-line);
  border-radius: 10px;
}

.lab-member-row-copy {
  min-width: 0;
  display: grid;
}

.lab-member-row-copy strong,
.lab-member-row-copy small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.lab-member-row-copy strong {
  font-size: 12px;
}

.lab-member-row-copy small {
  color: var(--lab-muted);
  font-size: 10px;
}

.lab-member-row-actions {
  display: flex;
  align-items: center;
  gap: 6px;
}

.lab-member-row-actions .lab-select {
  width: 96px;
  height: 34px;
  font-size: 11px;
}

.lab-member-invite {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 120px auto;
  gap: 8px;
  margin-bottom: 16px;
}

.lab-design-lock,
.lab-field-help {
  grid-column: 1 / -1;
  margin: 0;
  color: var(--lab-muted);
  font-size: 11px;
}

.lab-design-lock {
  display: flex;
  align-items: center;
  gap: 7px;
  padding-top: 10px;
  border-top: 1px solid var(--lab-line);
}

.lab-record-banner-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-left: auto;
}

.lab-record-evidence,
.lab-record-addendum {
  margin-top: 12px;
  padding: 11px 12px;
  border-radius: 9px;
  background: var(--lab-panel-soft);
}

.lab-record-evidence ul {
  margin: 7px 0 0;
  padding-left: 18px;
}

.lab-record-evidence small,
.lab-record-addendum small {
  color: var(--lab-muted);
}

.lab-record-addendum p {
  margin: 6px 0;
}

.lab-inline-check {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 12px;
  border: 1px solid var(--lab-line);
  border-radius: 10px;
  background: var(--lab-panel-soft);
  cursor: pointer;
}

.lab-inline-check input {
  margin-top: 3px;
}

.lab-inline-check span {
  display: grid;
  gap: 3px;
}

.lab-inline-check small {
  color: var(--lab-muted);
  font-weight: 400;
}

.lab-alert {
  position: fixed;
  top: 78px;
  right: 24px;
  width: min(380px, calc(100vw - 32px));
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 13px 14px;
  border: 1px solid #ebc6c0;
  border-radius: 11px;
  background: #fff;
  color: var(--lab-red);
  box-shadow: var(--lab-shadow-md);
  font-size: 12px;
  z-index: 120;
  animation: lab-toast-in 180ms ease-out;
  pointer-events: none;
}

.lab-alert.is-notice {
  border-color: #bdddc8;
  color: var(--lab-green-700);
}

.lab-alert p {
  flex: 1;
  margin: 0;
}

.lab-alert button {
  border: 0;
  background: transparent;
  color: inherit;
  cursor: pointer;
  pointer-events: auto;
}

.lab-loading {
  min-height: 55vh;
  display: grid;
  place-items: center;
  color: var(--lab-muted);
}

.lab-spinner {
  width: 24px;
  height: 24px;
  border: 2px solid #d2ded7;
  border-top-color: var(--lab-green-600);
  border-radius: 50%;
  animation: lab-spin 700ms linear infinite;
}

.lab-auth-shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(420px, 0.9fr);
  background: var(--lab-panel);
}

.lab-auth-story {
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: clamp(34px, 6vw, 76px);
  background: var(--lab-green-950);
  color: #fff;
}

.lab-auth-story::after {
  content: "";
  position: absolute;
  right: -160px;
  bottom: -160px;
  width: 520px;
  height: 520px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 50%;
  box-shadow:
    0 0 0 64px rgba(255, 255, 255, 0.022),
    0 0 0 128px rgba(255, 255, 255, 0.018);
}

.lab-auth-brand {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 11px;
  color: #fff;
  font-weight: 690;
  text-decoration: none;
}

.lab-auth-brand .lab-brand-mark {
  background: rgba(255, 255, 255, 0.1);
}

.lab-auth-copy {
  position: relative;
  z-index: 1;
  max-width: 650px;
  padding: 70px 0;
}

.lab-auth-copy h1 {
  margin: 0;
  font-size: clamp(38px, 5.2vw, 70px);
  font-weight: 660;
  letter-spacing: -0.055em;
  line-height: 1.02;
}

.lab-auth-copy > p {
  max-width: 580px;
  margin: 22px 0 0;
  color: #b8cec2;
  font-size: 16px;
}

.lab-auth-product-nav {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 18px;
}

.lab-auth-product-nav a {
  min-height: 34px;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: #9db7aa;
  font-size: 12px;
  font-weight: 650;
  text-decoration: none;
}

.lab-auth-product-nav a:hover,
.lab-auth-product-nav a:focus-visible {
  color: #fff;
  outline: none;
}

.lab-auth-panel {
  display: grid;
  place-items: center;
  padding: 34px;
}

.lab-auth-card {
  width: min(390px, 100%);
}

.lab-auth-card h2 {
  margin: 0;
  color: var(--lab-green-950);
  font-size: 27px;
  font-weight: 710;
  letter-spacing: -0.035em;
}

.lab-auth-card > p {
  margin: 8px 0 26px;
  color: var(--lab-muted);
  font-size: 13px;
}

.lab-auth-form {
  display: grid;
  gap: 15px;
}

.lab-auth-form .lab-button {
  margin-top: 3px;
  min-height: 44px;
}

.lab-auth-links {
  margin-top: 17px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: var(--lab-muted);
  font-size: 11px;
}

.lab-auth-links button,
.lab-auth-links a {
  padding: 0;
  border: 0;
  background: none;
  color: var(--lab-green-700);
  font: inherit;
  cursor: pointer;
}

.lab-auth-error {
  margin: 16px 0 0;
  padding: 10px 12px;
  border-radius: 9px;
  background: var(--lab-red-soft);
  color: var(--lab-red);
  font-size: 11px;
}

.lab-mobile-backdrop {
  display: none;
}

.lab-visually-hidden {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}

@keyframes lab-spin {
  to {
    transform: rotate(360deg);
  }
}

@keyframes lab-fade-in {
  from {
    opacity: 0;
  }
}

@keyframes lab-modal-in {
  from {
    opacity: 0;
    transform: translateY(8px) scale(0.985);
  }
}

@keyframes lab-toast-in {
  from {
    opacity: 0;
    transform: translateY(-7px);
  }
}

@media (max-width: 1040px) {
  :root {
    --lab-sidebar: 250px;
  }

  .lab-grid.is-two {
    grid-template-columns: 1fr;
  }

  .lab-science-summary {
    grid-template-columns: 1fr;
  }

  .lab-science-block {
    min-height: auto;
    border-right: 0;
    border-bottom: 1px solid var(--lab-line);
  }

  .lab-science-block:last-child {
    border-bottom: 0;
  }
}

@media (max-width: 820px) {
  .lab-shell {
    grid-template-columns: 1fr;
  }

  .lab-sidebar {
    position: fixed;
    left: 0;
    transform: translateX(-102%);
    width: min(84vw, 304px);
    transition: transform 180ms ease;
    box-shadow: 18px 0 60px rgba(5, 26, 18, 0.24);
  }

  .lab-shell.is-menu-open .lab-sidebar {
    transform: translateX(0);
  }

  .lab-mobile-backdrop {
    position: fixed;
    inset: 0 0 0 min(84vw, 304px);
    display: block;
    border: 0;
    background: rgba(8, 28, 21, 0.4);
    opacity: 0;
    pointer-events: none;
    z-index: 19;
    transition: opacity 180ms ease;
  }

  .lab-shell.is-menu-open .lab-mobile-backdrop {
    opacity: 1;
    pointer-events: auto;
  }

  button.lab-mobile-menu {
    display: inline-flex;
  }

  .lab-topbar {
    height: 58px;
    padding: 0 16px;
  }

  .lab-content {
    padding: 25px 17px 70px;
  }

  .lab-grid.is-projects {
    grid-template-columns: 1fr;
  }

  .lab-page-head {
    gap: 15px;
  }

  .lab-page-actions {
    flex-wrap: wrap;
    justify-content: flex-end;
  }

  .lab-synthesis-grid {
    grid-template-columns: 1fr;
  }

  .lab-synthesis-item,
  .lab-synthesis-item:nth-child(2n),
  .lab-synthesis-item:nth-last-child(-n + 2) {
    border-right: 0;
    border-bottom: 1px solid var(--lab-line);
  }

  .lab-synthesis-item:last-child {
    border-bottom: 0;
  }

  .lab-form-section-body {
    grid-template-columns: 1fr;
  }

  .lab-field.is-wide {
    grid-column: auto;
  }

  .lab-auth-shell {
    grid-template-columns: 1fr;
  }

  .lab-auth-story {
    min-height: 310px;
    padding: 27px;
  }

  .lab-auth-copy {
    padding: 48px 0 30px;
  }

  .lab-auth-copy h1 {
    font-size: clamp(34px, 10vw, 54px);
  }

  .lab-auth-copy > p {
    font-size: 14px;
  }

  .lab-auth-panel {
    padding: 35px 22px 55px;
  }
}

@media (max-width: 560px) {
  .lab-page-actions .lab-button.is-light span {
    display: none;
  }

  .lab-page-head {
    display: grid;
  }

  .lab-page-actions {
    justify-content: flex-start;
  }

  .lab-page-title h1 {
    font-size: 29px;
  }

  .lab-project-header {
    padding: 21px;
  }

  .lab-synthesis-empty,
  .lab-synthesis-top {
    align-items: flex-start;
    flex-direction: column;
  }

  .lab-question {
    grid-template-columns: 22px minmax(0, 1fr);
  }

  .lab-question-actions {
    grid-column: 2;
  }

  .lab-run-card {
    grid-template-columns: 45px minmax(0, 1fr);
  }

  .lab-run-number {
    width: 43px;
    height: 43px;
  }

  .lab-run-meta {
    grid-column: 2;
    justify-content: flex-start;
  }

  .lab-run-actions {
    bottom: 9px;
    align-items: flex-start;
    flex-direction: column;
    padding: 11px;
  }

  .lab-run-actions-buttons {
    width: 100%;
  }

  .lab-run-actions-buttons .lab-button {
    flex: 1;
  }

  .lab-modal-backdrop {
    align-items: end;
    padding: 0;
  }

  .lab-modal,
  .lab-modal.is-wide {
    width: 100%;
    max-height: 92vh;
    border-radius: 18px 18px 0 0;
  }

  .lab-modal-foot {
    padding-bottom: max(20px, env(safe-area-inset-bottom));
  }

  .lab-guide-tabs {
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 4px;
    overflow: visible;
  }

  .lab-guide-tab {
    min-height: 36px;
    gap: 0;
    padding: 5px 2px;
    font-size: 11px;
  }

  .lab-guide-tab .lab-icon {
    display: none;
  }

  .lab-guide-panel {
    min-height: 0;
  }

  .lab-guide-items {
    grid-template-columns: 1fr;
  }

  .lab-guide-item {
    min-height: 0;
  }

  .lab-guide-item.is-example:last-child:nth-child(odd) {
    grid-column: auto;
  }

  .lab-choice-grid {
    grid-template-columns: 1fr;
  }

  .lab-member-invite {
    grid-template-columns: 1fr 110px;
  }

  .lab-member-invite .lab-button {
    grid-column: 1 / -1;
  }

  .lab-member-row {
    grid-template-columns: 34px minmax(0, 1fr);
  }

  .lab-member-row-actions {
    grid-column: 2;
  }

  .lab-alert {
    top: 66px;
    right: 16px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
