:root {
  /* ove-three "modern lab SaaS" light theme tokens */
  --o3-bg-0: #f2f5f2; /* deepest / canvas */
  --o3-bg-1: #fcfdfc; /* chrome bars */
  --o3-bg-2: #f7f9f7; /* panels */
  --o3-bg-3: #eef2ef; /* raised controls / inputs */
  --o3-hover: #e4eae5;
  --o3-line: rgba(57, 78, 68, 0.18);
  --o3-line-soft: rgba(57, 78, 68, 0.1);
  --o3-text-1: #18271f; /* primary */
  --o3-text-2: #46584e; /* secondary */
  --o3-text-3: #6c7d73; /* hint */
  --o3-accent: #15a06a; /* emerald */
  --o3-accent-strong: #0d7d52;
  --o3-accent-weak: rgba(21, 160, 106, 0.12);
  --o3-accent-line: rgba(21, 160, 106, 0.34);
  --o3-on-accent: #ffffff;
  --o3-warn: #9a6212;
  --o3-warn-line: rgba(176, 117, 30, 0.36);
  --o3-warn-weak: rgba(176, 117, 30, 0.1);
  --o3-glass: rgba(255, 255, 255, 0.82);
  --o3-shadow-1: 0 1px 2px rgba(30, 50, 40, 0.08);
  --o3-shadow-2: 0 10px 30px rgba(30, 50, 40, 0.12);

  /* typography + motion */
  --o3-font-ui:
    "IBM Plex Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --o3-font-mono: "IBM Plex Mono", "SFMono-Regular", Consolas, monospace;
  --o3-ease: cubic-bezier(0.22, 1, 0.36, 1);
  --o3-dur: 0.36s;

  /* WebGL map structural colors (read from JS via getComputedStyle) */
  --o3-map-backbone: #2f7fd6;
  --o3-map-backbone-emissive: #0a1322;
  --o3-map-primer: #0d7d52;
  --o3-map-cutsite: #d9701a;
  --o3-map-cutsite-text: #9a4d12;
  --o3-map-complement: #8a9a90;
  --o3-map-guide: #c4d0c8;
  --o3-map-guide-opacity: 0.6;
}

:root[data-theme="dark"] {
  /* "precision lab instrument" dark theme — graphite + lime */
  --o3-bg-0: #0e1410;
  --o3-bg-1: #151d18;
  --o3-bg-2: #1a241d;
  --o3-bg-3: #212d25;
  --o3-hover: #2a3830;
  --o3-line: rgba(180, 200, 185, 0.16);
  --o3-line-soft: rgba(180, 200, 185, 0.08);
  --o3-text-1: #eaf2ec;
  --o3-text-2: #aebcb2;
  --o3-text-3: #7e8d83;
  --o3-accent: #a8e84c;
  --o3-accent-strong: #c4f06f;
  --o3-accent-weak: rgba(168, 232, 76, 0.16);
  --o3-accent-line: rgba(168, 232, 76, 0.4);
  --o3-on-accent: #122017;
  --o3-warn: #f5c451;
  --o3-warn-line: rgba(245, 196, 81, 0.4);
  --o3-warn-weak: rgba(245, 196, 81, 0.12);
  --o3-glass: rgba(14, 20, 16, 0.7);
  --o3-shadow-1: 0 1px 2px rgba(0, 0, 0, 0.4);
  --o3-shadow-2: 0 10px 30px rgba(0, 0, 0, 0.5);

  --o3-map-backbone: #5fb3ff;
  --o3-map-backbone-emissive: #0b3c66;
  --o3-map-primer: #67e8f9;
  --o3-map-cutsite: #fb923c;
  --o3-map-cutsite-text: #fed7aa;
  --o3-map-complement: #64748b;
  --o3-map-guide: #24364d;
  --o3-map-guide-opacity: 0.28;
}

.ove-three-viewer {
  position: relative;
  width: 100%;
  height: 100%;
  min-height: 480px;
  overflow: hidden;
  background: var(--o3-bg-0);
}

.ove-three-stats-gl {
  top: 12px !important;
  left: 12px !important;
  z-index: 5 !important;
  pointer-events: none !important;
}

.ove-three-scene-stats {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 5;
  width: 210px;
  padding: 10px 12px;
  border: 1px solid var(--o3-line);
  border-radius: 6px;
  background: var(--o3-glass);
  color: var(--o3-text-1);
  font-size: 12px;
  line-height: 1.35;
  backdrop-filter: blur(10px);
  pointer-events: none;
}

.ove-three-scene-stats__fixture {
  margin-bottom: 8px;
  overflow: hidden;
  color: var(--o3-text-1);
  font-weight: 600;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ove-three-scene-stats dl {
  display: grid;
  gap: 5px;
  margin: 0;
}

.ove-three-scene-stats dl div {
  display: flex;
  justify-content: space-between;
  gap: 12px;
}

.ove-three-scene-stats dt {
  color: var(--o3-text-3);
}

.ove-three-scene-stats dd {
  margin: 0;
  color: var(--o3-text-1);
  font-variant-numeric: tabular-nums;
}

.ove-three-picking-debug {
  position: absolute;
  bottom: 12px;
  left: 12px;
  z-index: 5;
  width: 210px;
  padding: 10px 12px;
  border: 1px solid var(--o3-warn-line);
  border-radius: 6px;
  background: var(--o3-glass);
  color: var(--o3-warn);
  font-size: 12px;
  line-height: 1.5;
  backdrop-filter: blur(10px);
}

.ove-three-pointer-debug {
  position: absolute;
  bottom: 96px;
  left: 12px;
  z-index: 5;
  width: 210px;
  padding: 10px 12px;
  border: 1px solid var(--o3-accent-line);
  border-radius: 6px;
  background: var(--o3-glass);
  color: var(--o3-text-1);
  font-size: 12px;
  line-height: 1.5;
  backdrop-filter: blur(10px);
}

.ove-three-edit-preview {
  position: absolute;
  bottom: 12px;
  left: 236px;
  z-index: 5;
  display: flex;
  gap: 10px;
  align-items: center;
  width: fit-content;
  max-width: min(520px, calc(100% - 260px));
  padding: 8px 10px;
  border: 1px solid var(--o3-warn-line);
  border-radius: 6px;
  background: var(--o3-glass);
  color: var(--o3-text-1);
  font-size: 12px;
  line-height: 1.35;
  pointer-events: none;
  backdrop-filter: blur(10px);
}

.ove-three-row-view {
  position: relative;
  width: 100%;
  height: 100%;
  min-height: 480px;
  overflow: hidden;
  background: var(--o3-bg-0);
}

.ove-three-row-canvas-sticky {
  position: absolute;
  inset: 0;
  z-index: 1;
  min-height: 0;
  pointer-events: auto;
}

.ove-three-row-scroll-spacer {
  display: none;
  pointer-events: none;
}

.ove-three-row-debug {
  position: absolute;
  top: 12px;
  left: 12px;
  z-index: 4;
  width: fit-content;
  padding: 8px 10px;
  border: 1px solid var(--o3-accent-line);
  border-radius: 6px;
  margin: 0;
  background: var(--o3-glass);
  color: var(--o3-text-1);
  font-size: 12px;
  line-height: 1.35;
  backdrop-filter: blur(10px);
}

.ove-three-row-debug div {
  color: var(--o3-text-3);
}

.ove-three-row-smoke-layer {
  position: absolute;
  right: 14px;
  bottom: 14px;
  z-index: 3;
  padding: 7px 10px;
  border: 1px solid var(--o3-accent-line);
  border-radius: 6px;
  background: var(--o3-bg-2);
  color: var(--o3-text-1);
  font-size: 12px;
  pointer-events: none;
}

.ove-three-row-smoke-layer--chromatogram {
  bottom: 48px;
}

.ove-three-editor {
  display: grid;
  grid-template-rows: 52px auto minmax(0, 1fr) 42px;
  height: 100vh;
  min-height: 100vh;
  overflow: hidden;
  background: var(--o3-bg-0);
  color: var(--o3-text-1);
  font-family:
    Inter,
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    sans-serif;
}

.ove-three-editor__chrome {
  display: flex;
  gap: 18px;
  align-items: center;
  border-bottom: 1px solid var(--o3-line-soft);
  padding: 0 18px;
  background: var(--o3-bg-1);
}

.ove-three-editor__identity {
  display: grid;
  flex: 0 0 220px;
  gap: 2px;
  min-width: 0;
}

.ove-three-editor__identity strong {
  color: var(--o3-text-1);
  font-size: 14px;
}

.ove-three-editor__identity span {
  overflow: hidden;
  color: var(--o3-text-3);
  font-size: 12px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ove-three-editor__menu,
.ove-three-editor__toolbar,
.ove-three-editor__panel-actions {
  display: flex;
  gap: 4px;
  align-items: center;
}

.ove-three-editor__menu {
  position: relative;
  z-index: 2;
  flex: 1 1 auto;
  justify-content: flex-start;
  min-width: 260px;
}

.ove-three-editor__toolbar {
  position: relative;
  flex: 0 0 auto;
  z-index: 1;
}

.ove-three-editor__panel-actions {
  flex: 0 0 auto;
}

.ove-three-editor__menu button,
.ove-three-editor__toolbar button,
.ove-three-editor__panel-actions button,
.ove-three-editor__tabs button,
.ove-three-editor__status-bar button {
  border: 1px solid transparent;
  border-radius: 6px;
  background: transparent;
  color: var(--o3-text-2);
  cursor: pointer;
  font: inherit;
}

.ove-three-editor__menu button {
  padding: 7px 10px;
}

.ove-three-editor__toolbar button {
  border-color: var(--o3-line);
  padding: 7px 10px;
  background: var(--o3-bg-3);
}

.ove-three-editor__menu button.is-active {
  border-color: var(--o3-accent-line);
  background: var(--o3-accent-weak);
  color: var(--o3-text-1);
}

.ove-three-editor__panel-actions button {
  border-color: var(--o3-line);
  padding: 7px 8px;
  background: var(--o3-bg-3);
  font-size: 12px;
}

.ove-three-editor__menu button:hover,
.ove-three-editor__toolbar button:hover,
.ove-three-editor__panel-actions button:hover,
.ove-three-editor__tabs button:hover:not(:disabled),
.ove-three-editor__status-bar button:hover {
  border-color: var(--o3-accent-line);
  background: var(--o3-accent-weak);
  color: var(--o3-text-1);
}

.ove-three-editor__body {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  min-height: 0;
  overflow: hidden;
}

.ove-three-editor__command-shelf {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 44px;
  border-bottom: 1px solid var(--o3-line-soft);
  padding: 7px 18px;
  background: var(--o3-bg-0);
  color: var(--o3-text-1);
  font-size: 12px;
}

.ove-three-editor__command-shelf > div {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.ove-three-editor__command-shelf button {
  border: 1px solid var(--o3-line);
  border-radius: 6px;
  padding: 5px 8px;
  background: var(--o3-bg-3);
  color: var(--o3-text-1);
  cursor: pointer;
}

.ove-three-editor__command-shelf button:hover:not(:disabled) {
  border-color: var(--o3-accent-line);
  background: var(--o3-accent-weak);
}

.ove-three-editor__command-shelf button:disabled,
.ove-three-editor__toolbar button:disabled,
.ove-three-editor__status-bar button:disabled {
  cursor: not-allowed;
  opacity: 0.45;
}

.ove-three-editor.is-fullscreen .ove-three-editor__body,
.ove-three-editor.is-side-panel-collapsed .ove-three-editor__body {
  grid-template-columns: minmax(0, 1fr);
}

.ove-three-editor.is-fullscreen .ove-three-demo__panel,
.ove-three-editor.is-side-panel-collapsed .ove-three-demo__panel {
  display: none;
}

.ove-three-editor__main {
  display: grid;
  grid-template-rows: 42px auto minmax(0, 1fr);
  min-height: 0;
}

.ove-three-editor__tabs {
  position: relative;
  z-index: 8;
  display: flex;
  align-items: end;
  gap: 18px;
  border-bottom: 1px solid var(--o3-line-soft);
  padding: 0 18px;
  background: var(--o3-bg-1);
}

.ove-three-editor__tabs button {
  height: 100%;
  border-radius: 0;
  padding: 0 2px;
  border-bottom: 2px solid transparent;
  color: var(--o3-text-3);
}

.ove-three-editor__tabs button.is-active {
  border-bottom-color: var(--o3-accent);
  color: var(--o3-text-1);
}

.ove-three-editor__tabs button:disabled {
  cursor: not-allowed;
  opacity: 0.45;
}

.ove-three-editor__view-options {
  position: relative;
  z-index: 9;
  display: flex;
  align-items: center;
  gap: 14px;
  min-height: 44px;
  border-bottom: 1px solid var(--o3-line-soft);
  padding: 8px 18px;
  background: var(--o3-bg-0);
}

.ove-three-editor__circular-controls,
.ove-three-editor__linear-controls,
.ove-three-editor__row-controls {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  width: 100%;
  color: var(--o3-text-2);
  font-size: 12px;
}

.ove-three-editor__circular-controls label,
.ove-three-editor__linear-controls label,
.ove-three-editor__row-controls label {
  display: flex;
  align-items: center;
  gap: 8px;
}

.ove-three-editor__circular-controls input,
.ove-three-editor__linear-controls input,
.ove-three-editor__row-controls input[type="range"] {
  width: 120px;
}

.ove-three-editor__stepper {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  padding: 0;
  border: 1px solid var(--o3-border, #2b3344);
  border-radius: 6px;
  background: var(--o3-bg-2, #1b2230);
  color: var(--o3-text-1, #e6edf6);
  font-size: 15px;
  line-height: 1;
  cursor: pointer;
  user-select: none;
}

.ove-three-editor__stepper:hover {
  border-color: var(--o3-accent, #a8e84c);
  color: var(--o3-accent, #a8e84c);
}

.ove-three-editor__stepper:active {
  transform: translateY(1px);
}

.ove-three-editor__layer-summary,
.ove-three-editor__fit-summary {
  color: var(--o3-text-2);
  font-size: 12px;
}

.ove-three-editor__linear-title {
  color: var(--o3-text-1);
  font-weight: 700;
}

.ove-three-editor__minimap {
  position: relative;
  width: 36px;
  height: 36px;
  flex: 0 0 36px;
  border: 1px solid var(--o3-accent-line);
  border-radius: 50%;
  background:
    radial-gradient(circle, var(--o3-bg-0) 48%, transparent 50%),
    conic-gradient(
      from var(--rotation),
      var(--o3-accent) 0 35deg,
      var(--o3-hover) 35deg 360deg
    );
}

.ove-three-editor__minimap span {
  position: absolute;
  top: 4px;
  left: 50%;
  width: calc(12px / var(--zoom));
  min-width: 5px;
  height: 4px;
  border-radius: 999px;
  background: var(--o3-text-1);
  transform: translateX(-50%);
}

.ove-three-editor__sequence-preview {
  max-width: 260px;
  overflow: hidden;
  color: var(--o3-text-1);
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ove-three-editor__canvas {
  position: relative;
  min-height: 0;
  overflow: hidden;
}

.ove-three-linked-map {
  display: grid;
  grid-template-columns: minmax(320px, 1fr) minmax(420px, 1.15fr);
  gap: 1px;
  height: 100%;
  min-height: 0;
  background: var(--o3-line-soft);
}

.ove-three-linked-map.is-sequence-collapsed {
  grid-template-columns: minmax(320px, 1fr) 72px;
}

.ove-three-linked-map__pane {
  position: relative;
  display: grid;
  grid-template-rows: 32px minmax(0, 1fr);
  min-width: 0;
  min-height: 0;
  overflow: hidden;
  background: var(--o3-bg-0);
}

.ove-three-linked-map__pane-title {
  position: relative;
  z-index: 7;
  display: flex;
  justify-content: space-between;
  gap: 8px;
  align-items: center;
  border-bottom: 1px solid var(--o3-line-soft);
  padding: 0 12px;
  background: var(--o3-bg-1);
  color: var(--o3-text-1);
  font-size: 12px;
  font-weight: 700;
}

.ove-three-linked-map__pane-title button {
  border: 1px solid var(--o3-line);
  border-radius: 4px;
  padding: 3px 8px;
  background: var(--o3-bg-3);
  color: var(--o3-text-1);
  font: inherit;
  cursor: pointer;
}

.ove-three-linked-map__pane-title button:hover {
  border-color: var(--o3-accent-line);
}

.ove-three-linked-map__switch {
  display: inline-flex;
  overflow: hidden;
  border: 1px solid var(--o3-line);
  border-radius: 5px;
}

.ove-three-linked-map__switch button {
  border: 0;
  border-radius: 0;
  padding: 3px 7px;
  background: var(--o3-bg-3);
}

.ove-three-linked-map__switch button.is-active {
  background: var(--o3-accent-weak);
  color: var(--o3-text-1);
}

.ove-three-linked-map__rail {
  display: flex;
  flex-direction: column;
  gap: 12px;
  align-items: center;
  justify-content: center;
  min-width: 0;
  min-height: 0;
  border-left: 1px solid var(--o3-line-soft);
  background: var(--o3-bg-1);
  color: var(--o3-text-1);
  font-size: 12px;
  font-weight: 700;
}

.ove-three-linked-map__rail span,
.ove-three-linked-map__rail button {
  writing-mode: vertical-rl;
  transform: rotate(180deg);
}

.ove-three-linked-map__rail button {
  border: 1px solid var(--o3-accent-line);
  border-radius: 4px;
  padding: 8px 5px;
  background: var(--o3-accent-weak);
  color: var(--o3-accent-strong);
  font: inherit;
  cursor: pointer;
}

.ove-three-linked-map__rail button:hover {
  border-color: var(--o3-accent-line);
  background: var(--o3-hover);
}

.ove-three-linked-map__viewer,
.ove-three-linked-map__viewer .ove-three-row-view {
  min-height: 0;
}

.ove-three-linked-map__viewer .ove-three-edit-preview {
  left: 12px;
  max-width: calc(100% - 24px);
}

.ove-three-linked-map__viewer .ove-three-scene-stats {
  width: 190px;
}

.ove-three-viewer > [data-testid="ove-three-webgl-canvas"],
.ove-three-row-canvas-sticky > [data-testid="ove-three-webgl-canvas"] {
  width: 100% !important;
  height: 100% !important;
}

.ove-three-viewer > [data-testid="ove-three-webgl-canvas"] canvas,
.ove-three-row-canvas-sticky > [data-testid="ove-three-webgl-canvas"] canvas {
  display: block;
  width: 100% !important;
  height: 100% !important;
}

.ove-three-editor__closed-panel {
  display: grid;
  place-content: center;
  gap: 12px;
  height: 100%;
  min-height: 420px;
  background: var(--o3-bg-0);
  color: var(--o3-text-1);
}

.ove-three-editor__closed-panel button {
  border: 1px solid var(--o3-accent-line);
  border-radius: 6px;
  padding: 8px 10px;
  background: var(--o3-accent-weak);
  color: var(--o3-accent-strong);
  cursor: pointer;
}

.ove-three-editor__properties-panel,
.ove-three-editor__genbank-panel,
.ove-three-editor__preview-panel {
  height: 100%;
  min-height: 420px;
  overflow: auto;
  padding: 24px;
  background: var(--o3-bg-0);
  color: var(--o3-text-1);
}

.ove-three-editor__properties-panel h2,
.ove-three-editor__preview-panel h2 {
  margin: 0 0 16px;
  color: var(--o3-text-1);
}

.ove-three-editor__properties-panel dl,
.ove-three-demo__command-status dl {
  display: grid;
  gap: 10px;
  margin: 0 0 16px;
}

.ove-three-editor__properties-panel dl div,
.ove-three-demo__command-status dl div {
  display: grid;
  grid-template-columns: 110px minmax(0, 1fr);
  gap: 12px;
}

.ove-three-editor__properties-panel dt,
.ove-three-demo__command-status dt {
  color: var(--o3-text-3);
}

.ove-three-editor__properties-panel dd,
.ove-three-demo__command-status dd {
  margin: 0;
  min-width: 0;
  overflow-wrap: anywhere;
}

.ove-three-editor__genbank-panel,
.ove-three-demo__advanced-tools pre {
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  white-space: pre-wrap;
}

.ove-three-editor__preview-panel {
  display: grid;
  place-content: center;
  gap: 12px;
  text-align: center;
}

.ove-three-editor__preview-panel button {
  border: 1px solid var(--o3-accent-line);
  border-radius: 6px;
  padding: 8px 12px;
  background: var(--o3-accent-weak);
  color: var(--o3-accent-strong);
  cursor: pointer;
}

.ove-three-editor__gc-aa-plot {
  position: absolute;
  right: 18px;
  bottom: 18px;
  z-index: 6;
  min-width: 220px;
  padding: 10px 12px;
  border: 1px solid var(--o3-accent-line);
  border-radius: 6px;
  background: var(--o3-glass);
  color: var(--o3-text-1);
  font-size: 12px;
  backdrop-filter: blur(10px);
}

.ove-three-editor__canvas > .ove-three-viewer,
.ove-three-editor__canvas > .ove-three-row-view {
  min-height: 0;
}

.ove-three-editor__status-bar {
  display: grid;
  grid-template-columns: 90px 130px 120px 140px minmax(0, 1fr) 130px 170px;
  align-items: center;
  border-top: 1px solid var(--o3-line-soft);
  background: var(--o3-bg-1);
  color: var(--o3-text-2);
  font-size: 13px;
}

.ove-three-editor__status-bar span,
.ove-three-editor__status-bar select,
.ove-three-editor__status-bar button {
  display: flex;
  align-items: center;
  height: 100%;
  min-width: 0;
  border-right: 1px solid var(--o3-line-soft);
  padding: 0 14px;
}

.ove-three-editor__status-bar span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ove-three-editor__status-bar select {
  border: 0;
  border-right: 1px solid var(--o3-line-soft);
  background: var(--o3-bg-1);
  color: var(--o3-text-1);
}

.ove-three-demo {
  min-height: 100vh;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  background: var(--o3-bg-0);
  color: var(--o3-text-1);
  font-family:
    Inter,
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    sans-serif;
}

.ove-three-demo__viewer {
  min-height: 100vh;
}

.ove-three-editor .ove-three-demo__viewer {
  min-height: 0;
}

.ove-three-demo__panel {
  max-height: 100vh;
  overflow: auto;
  padding: 20px;
  background: var(--o3-glass);
  border-left: 1px solid var(--o3-line);
}

.ove-three-editor .ove-three-demo__panel {
  max-height: 100%;
  min-height: 0;
  overflow: auto;
}

.ove-three-demo__panel h1 {
  margin: 0 0 6px;
  font-size: 20px;
}

.ove-three-demo__panel p {
  margin: 0 0 18px;
  color: var(--o3-text-3);
}

.ove-three-demo__features {
  display: grid;
  gap: 12px;
}

.ove-three-demo__command-status,
.ove-three-demo__advanced-tools {
  display: grid;
  gap: 10px;
  margin: 16px 0;
  border-bottom: 1px solid var(--o3-line-soft);
  padding-bottom: 14px;
}

.ove-three-demo__command-status h2,
.ove-three-demo__advanced-tools h2 {
  margin: 0;
  color: var(--o3-text-1);
  font-size: 13px;
}

.ove-three-demo__advanced-tools pre {
  max-height: 140px;
  overflow: auto;
  margin: 0;
  border: 1px solid var(--o3-line-soft);
  border-radius: 6px;
  padding: 8px;
  background: var(--o3-bg-1);
  color: var(--o3-text-1);
  font-size: 11px;
}

.ove-three-demo__features h2 {
  margin: 0;
  color: var(--o3-text-1);
  font-size: 13px;
  font-weight: 700;
}

.ove-three-demo__search {
  display: grid;
  gap: 6px;
  color: var(--o3-text-2);
  font-size: 12px;
}

.ove-three-demo__search input {
  width: 100%;
  border: 1px solid var(--o3-line);
  border-radius: 6px;
  padding: 7px 8px;
  background: var(--o3-bg-3);
  color: var(--o3-text-1);
}

.ove-three-demo__search input::placeholder {
  color: var(--o3-text-3);
}

.ove-three-demo__empty {
  margin: 0;
  color: var(--o3-text-3);
  font-size: 13px;
}

.ove-three-demo__annotation-tools {
  display: grid;
  grid-template-columns: 1fr auto auto auto;
  gap: 6px;
  align-items: center;
  color: var(--o3-text-3);
  font-size: 12px;
}

.ove-three-demo__annotation-tools button {
  border: 1px solid var(--o3-line);
  border-radius: 6px;
  padding: 5px 7px;
  background: var(--o3-bg-3);
  color: var(--o3-text-1);
  cursor: pointer;
}

.ove-three-demo__annotation-tools button:hover:not(:disabled) {
  background: var(--o3-accent-weak);
}

.ove-three-demo__annotation-tools button:disabled {
  cursor: not-allowed;
  opacity: 0.46;
}

.ove-three-demo__annotation-group {
  display: grid;
  gap: 4px;
}

.ove-three-demo__annotation-group h3 {
  margin: 4px 0 0;
  color: var(--o3-text-3);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
}

.ove-three-demo__layers {
  padding: 4px 0 8px;
  margin-bottom: 12px;
  border-bottom: 1px solid var(--o3-line-soft);
}

.ove-three-demo__layers h2 {
  margin: 0 0 10px;
  color: var(--o3-text-1);
  font-size: 13px;
  font-weight: 700;
}

.ove-three-demo__toggle {
  display: flex;
  gap: 8px;
  align-items: center;
  margin-bottom: 16px;
  color: var(--o3-text-2);
  font-size: 13px;
}

.ove-three-demo__field {
  display: grid;
  gap: 6px;
  margin-bottom: 16px;
  color: var(--o3-text-2);
  font-size: 13px;
}

.ove-three-demo__field select {
  width: 100%;
  border: 1px solid var(--o3-line);
  border-radius: 6px;
  padding: 7px 8px;
  background: var(--o3-bg-3);
  color: var(--o3-text-1);
}

.ove-three-demo__field input {
  width: 100%;
  border: 1px solid var(--o3-line);
  border-radius: 6px;
  padding: 7px 8px;
  background: var(--o3-bg-3);
  color: var(--o3-text-1);
}

.ove-three-demo__field input[type="range"] {
  padding: 0;
}

.ove-three-demo__warning {
  padding: 8px 10px;
  border: 1px solid var(--o3-warn-line);
  border-radius: 6px;
  margin: 0 0 14px;
  background: var(--o3-warn-weak);
  color: var(--o3-warn);
  font-size: 12px;
}

.ove-three-demo__button {
  width: 100%;
  border: 1px solid var(--o3-accent-line);
  border-radius: 6px;
  padding: 9px 10px;
  margin: 0 0 16px;
  background: var(--o3-accent-weak);
  color: var(--o3-accent-strong);
  cursor: pointer;
  font-weight: 600;
}

.ove-three-demo__button:hover {
  background: var(--o3-hover);
}

.ove-three-demo__verification {
  display: grid;
  gap: 8px;
  padding: 10px 0 16px;
  border-top: 1px solid var(--o3-line-soft);
  border-bottom: 1px solid var(--o3-line-soft);
  margin-bottom: 16px;
  font-size: 12px;
}

.ove-three-demo__verification div {
  display: grid;
  grid-template-columns: 100px 1fr;
  gap: 8px;
}

.ove-three-demo__verification span {
  color: var(--o3-text-3);
}

.ove-three-demo__verification strong {
  overflow: hidden;
  color: var(--o3-text-1);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ove-three-demo__feature {
  display: grid;
  grid-template-columns: 10px 1fr auto;
  gap: 10px;
  align-items: center;
  width: 100%;
  border: 0;
  padding: 8px 0;
  border-bottom: 1px solid var(--o3-line-soft);
  background: transparent;
  color: var(--o3-text-1);
  cursor: pointer;
  text-align: left;
  font-size: 13px;
}

.ove-three-demo__feature:hover,
.ove-three-demo__feature.is-selected {
  color: var(--o3-text-1);
}

.ove-three-demo__feature.is-selected .ove-three-demo__range {
  color: var(--o3-text-1);
}

.ove-three-demo__swatch {
  width: 10px;
  height: 22px;
  border-radius: 4px;
}

.ove-three-demo__range {
  color: var(--o3-text-3);
}

.ove-three-demo__selected-card {
  display: grid;
  gap: 10px;
  padding: 12px;
  border: 1px solid var(--o3-line);
  border-radius: 6px;
  margin: 16px 0;
  background: var(--o3-bg-3);
}

.ove-three-demo__selected-card h2 {
  margin: 0;
  color: var(--o3-text-1);
  font-size: 13px;
}

.ove-three-demo__selected-card p {
  margin: 0;
  color: var(--o3-text-1);
  font-weight: 700;
}

.ove-three-demo__selected-card dl {
  display: grid;
  gap: 6px;
  margin: 0;
}

.ove-three-demo__selected-card dl div {
  display: grid;
  grid-template-columns: 64px 1fr;
  gap: 8px;
  font-size: 12px;
}

.ove-three-demo__selected-card dt {
  color: var(--o3-text-3);
}

.ove-three-demo__selected-card dd {
  margin: 0;
  color: var(--o3-text-1);
}

.ove-three-demo__selected-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.ove-three-demo__selected-actions button {
  border: 1px solid var(--o3-accent-line);
  border-radius: 6px;
  padding: 7px 8px;
  background: var(--o3-accent-weak);
  color: var(--o3-accent-strong);
  cursor: pointer;
  font-weight: 600;
}

.ove-three-demo__selected-actions button:hover {
  background: var(--o3-hover);
}

.ove-three-demo__recent {
  display: grid;
  gap: 8px;
  padding: 12px 0;
  border-top: 1px solid var(--o3-line-soft);
  border-bottom: 1px solid var(--o3-line-soft);
  margin-bottom: 14px;
}

.ove-three-demo__recent-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.ove-three-demo__recent-header h2 {
  margin: 0;
  color: var(--o3-text-1);
  font-size: 13px;
}

.ove-three-demo__recent-header button {
  border: 1px solid var(--o3-line);
  border-radius: 6px;
  padding: 5px 7px;
  background: var(--o3-bg-3);
  color: var(--o3-text-1);
  cursor: pointer;
}

.ove-three-demo__recent-header button:disabled {
  cursor: not-allowed;
  opacity: 0.46;
}

.ove-three-demo__recent-item {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
  width: 100%;
  border: 1px solid var(--o3-line-soft);
  border-radius: 6px;
  padding: 7px 8px;
  background: var(--o3-bg-3);
  color: var(--o3-text-1);
  cursor: pointer;
  text-align: left;
  font-size: 12px;
}

.ove-three-demo__recent-item:hover,
.ove-three-demo__recent-item.is-selected {
  border-color: var(--o3-accent-line);
  background: var(--o3-accent-weak);
}

.ove-three-demo__recent-item span:first-child {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ove-three-demo__recent-item span:last-child {
  color: var(--o3-text-3);
}

.ove-three-demo__recent p {
  margin: 0;
  color: var(--o3-text-3);
  font-size: 12px;
}

/* ============================================================
   MODERN POLISH — align running app with docs/mockups
   ============================================================ */

/* typography */
.ove-three-editor,
.ove-three-demo {
  font-family: var(--o3-font-ui);
  letter-spacing: -0.005em;
}
.ove-three-editor__sequence-preview,
.ove-three-editor__genbank-panel,
.ove-three-demo__advanced-tools pre,
.ove-three-scene-stats dd,
.ove-three-demo__range,
.ove-three-demo__feature .ove-three-demo__range,
.ove-three-editor__status-bar span:has(> .ove-three-mono),
.ove-three-demo__recent-item span:last-child {
  font-family: var(--o3-font-mono);
}

/* tint native controls */
.ove-three-editor input,
.ove-three-editor select,
.ove-three-demo input,
.ove-three-demo select {
  accent-color: var(--o3-accent);
}

/* custom range sliders (match mockup) */
.ove-three-editor input[type="range"],
.ove-three-demo input[type="range"] {
  -webkit-appearance: none;
  appearance: none;
  height: 18px;
  background: transparent;
  cursor: pointer;
}
.ove-three-editor input[type="range"]::-webkit-slider-runnable-track,
.ove-three-demo input[type="range"]::-webkit-slider-runnable-track {
  height: 4px;
  border-radius: 99px;
  background: var(--o3-bg-3);
}
.ove-three-editor input[type="range"]::-moz-range-track,
.ove-three-demo input[type="range"]::-moz-range-track {
  height: 4px;
  border-radius: 99px;
  background: var(--o3-bg-3);
}
.ove-three-editor input[type="range"]::-webkit-slider-thumb,
.ove-three-demo input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 14px;
  height: 14px;
  margin-top: -5px;
  border-radius: 50%;
  background: var(--o3-accent);
  border: 2px solid var(--o3-bg-1);
  box-shadow: 0 0 0 1px var(--o3-accent-line);
  transition: transform 0.12s var(--o3-ease);
}
.ove-three-editor input[type="range"]::-webkit-slider-thumb:hover,
.ove-three-demo input[type="range"]::-webkit-slider-thumb:hover {
  transform: scale(1.18);
}
.ove-three-editor input[type="range"]::-moz-range-thumb,
.ove-three-demo input[type="range"]::-moz-range-thumb {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--o3-accent);
  border: 2px solid var(--o3-bg-1);
}

/* elevation on floating surfaces + panel + cards */
.ove-three-demo__panel {
  box-shadow: var(--o3-shadow-2);
}
.ove-three-scene-stats,
.ove-three-picking-debug,
.ove-three-pointer-debug,
.ove-three-edit-preview,
.ove-three-editor__gc-aa-plot,
.ove-three-row-debug {
  box-shadow: var(--o3-shadow-2);
}
.ove-three-demo__selected-card {
  box-shadow: var(--o3-shadow-1);
}

/* motion on interactive surfaces */
.ove-three-editor button,
.ove-three-demo button,
.ove-three-editor__tabs button {
  transition:
    background 0.16s var(--o3-ease),
    color 0.16s var(--o3-ease),
    border-color 0.16s var(--o3-ease),
    box-shadow 0.16s var(--o3-ease),
    transform 0.1s var(--o3-ease);
}
.ove-three-editor button:active:not(:disabled),
.ove-three-demo button:active:not(:disabled) {
  transform: scale(0.97);
}
.ove-three-demo__feature,
.ove-three-demo__recent-item {
  transition:
    background 0.14s var(--o3-ease),
    color 0.14s var(--o3-ease),
    transform 0.12s var(--o3-ease);
}
.ove-three-demo__feature:hover,
.ove-three-demo__recent-item:hover {
  transform: translateX(2px);
}

/* primary call-to-action buttons → solid accent */
.ove-three-demo__button {
  background: var(--o3-accent);
  color: var(--o3-on-accent);
  border-color: transparent;
}
.ove-three-demo__button:hover {
  background: var(--o3-accent);
  filter: brightness(1.06);
}

/* prominent, discoverable theme toggle */
.ove-three-theme-toggle {
  /* hidden while features are in development; re-enable for the styling pass */
  display: none !important;
  align-items: center;
  gap: 6px;
  border-color: var(--o3-accent-line) !important;
  color: var(--o3-accent-strong) !important;
}
.ove-three-theme-toggle:hover {
  background: var(--o3-accent-weak) !important;
}
.ove-three-theme-toggle svg {
  width: 14px;
  height: 14px;
}

@media (prefers-reduced-motion: reduce) {
  .ove-three-editor *,
  .ove-three-demo * {
    transition: none !important;
  }
}
