@font-face {
  font-family: Inter;
  src: url(/assets/fonts/InterVariable.woff2) format("woff2");
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
}
@font-face {
  font-family: Plex;
  src: url(/assets/fonts/IBMPlexMono-Regular.woff2) format("woff2");
  font-display: swap;
}
:root {
  color-scheme: light;
  --bg:#fafaf8; --surface:#efefed; --hover:#e1e1e0; --line:#d3d3d2;
  --text:#1b1b1d; --muted:#646468; --subtle:#707075; --accent:#535861;
  --panel:#fafaf8f5; --selected:#e0e4eb; --field:#f7f7f5; --signal:#526a8a;
  --stage-top:#f5f5f3; --stage-mid:#eeeeeC; --stage-bottom:#e8e8e6;
  --cad-blue:#435f84; --cad-highlight:#345b98;
}
[data-theme=dark] {
  color-scheme: dark;
  --bg:#18181a; --surface:#242426; --hover:#323236; --line:#3b3b40;
  --text:#ededeb; --muted:#ababaf; --subtle:#929297; --accent:#b9bdc5;
  --panel:#242426f5; --selected:#353840; --field:#1e1e20; --signal:#a4b6d2;
  --stage-top:#29292c; --stage-mid:#202023; --stage-bottom:#18181a;
  --cad-blue:#b6c9ef; --cad-highlight:#e3ebfa;
}
* {
  box-sizing: border-box;
}
html,
body {
  margin: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  background: var(--bg);
}
body,
button,
input,
select {
  font-family:
    Inter,
    Arial,
    sans-serif;
  font-size: 12px;
  color: var(--text);
}
button,
input,
select {
  font: inherit;
}
button {
  cursor: pointer;
  background: transparent;
  border: 0;
  color: inherit;
}
button:disabled {
  opacity: .35;
  cursor: default;
}
button:focus-visible,
input:focus-visible,
select:focus-visible,
canvas:focus-visible,
[tabindex]:focus-visible {
  outline: 2px solid var(--signal);
  outline-offset: 3px;
}
button:active:not(:disabled) {
  transform: translateY(1px);
}
button,
select,
input {
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
}
svg {
  width: 18px;
  height: 18px;
  display: block;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.45;
  stroke-linecap: round;
  stroke-linejoin: round;
}
[data-icon] {
  display: inline-flex;
  flex: none;
  align-items: center;
  justify-content: center;
}
img {
  display: block;
}
button[hidden],
[hidden] {
  display: none !important;
}
.muted {
  color: var(--muted);
  font-size: 10px;
}
.workbench {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 300px;
  width: 100%;
  height: 100%;
  position: relative;
  isolation: isolate;
}
.workbench.agent-collapsed {
  grid-template-columns: minmax(0, 1fr) 0;
}
.mini-viewer {
  position: relative;
  min-width: 0;
  height: 100%;
  overflow: hidden;
  background:
    radial-gradient(
      ellipse at 50% 30%,
      var(--stage-top) 0%,
      var(--stage-mid) 55%,
      var(--stage-bottom) 100%);
}
.mini-canvas-wrap {
  position: absolute;
  inset: 0;
  transition: left 180ms ease;
}
.mini-canvas-wrap canvas {
  display: block;
  width: 100%;
  height: 100%;
  touch-action: none;
}
.mini-fallback {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  font-size: 12px;
  color: var(--muted);
  pointer-events: none;
  padding: 24px;
  text-align: center;
}
.is-ready .mini-fallback {
  display: none;
}
.workspace-nav {
  position: absolute;
  top: 17px;
  left: 16px;
  z-index: 7;
  display: flex;
  flex-direction: column;
  align-items: start;
  gap: 8px;
}
.library-trigger,
.parts-trigger {
  display: flex;
  align-items: center;
  gap: 9px;
  border: 1px solid var(--line);
  background: var(--panel);
  box-shadow: 0 2px 6px #0002;
  border-radius: 10px;
  padding: 0 11px;
  min-height: 36px;
  backdrop-filter: blur(14px);
  font-size: 11px;
}
.library-trigger:hover,
.parts-trigger:hover {
  background: var(--hover);
}
.library-trigger svg {
  width: 14px;
  height: 14px;
}
.library-trigger > span:last-child {
  padding-left: 7px;
  border-left: 1px solid var(--line);
  margin-left: 4px;
}
.parts-trigger span:last-child {
  font-family: Plex, monospace;
  font-size: 10px;
  color: var(--muted);
}
.parts-trigger[aria-expanded=true] {
  background: var(--hover);
  border-color: var(--line);
}
.project-title {
  font-size: 10px;
  color: var(--muted);
  padding-left: 3px;
  margin: 0 0 3px;
  max-width: 250px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.workspace-actions {
  position: absolute;
  right: 16px;
  top: 16px;
  display: flex;
  align-items: center;
  gap: 7px;
  z-index: 7;
}
.icon-button {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 9px;
  color: var(--accent);
  flex: none;
}
.icon-button:hover {
  color: var(--text);
  background: var(--hover);
}
.workspace-actions > .icon-button {
  border: 1px solid var(--line);
  background: var(--panel);
}
.agent-toggle {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: var(--surface);
  box-shadow: 0 2px 8px #0002;
  margin-left: 3px;
}
.agent-toggle:hover {
  background: var(--hover);
  border-color: var(--line);
}
.agent-toggle[aria-expanded=true] {
  border-color: var(--line);
}
.floating-panel {
  position: absolute;
  z-index: 12;
  border: 1px solid var(--line);
  background: var(--panel);
  border-radius: 12px;
  box-shadow: 0 12px 36px #0005;
  backdrop-filter: blur(20px);
}
.panel-heading {
  display: flex;
  gap: 10px;
  align-items: center;
  min-height: 43px;
  padding: 6px 11px 6px 16px;
  border-bottom: 1px solid var(--line);
}
.panel-heading strong {
  font-size: 12px;
  font-weight: 550;
}
.panel-heading > .icon-button {
  margin-left: auto;
  width: 30px;
  height: 30px;
}
.panel-heading output {
  color: var(--muted);
  font-size: 11px;
  font-family: Plex, monospace;
}
.project-library {
  top: 60px;
  left: 16px;
  width: 272px;
}
.mini-projects {
  padding: 6px;
}
.mini-projects > button {
  display: flex;
  align-items: center;
  width: 100%;
  gap: 12px;
  text-align: left;
  padding: 12px 11px;
  border-radius: 8px;
  min-height: 66px;
}
.mini-projects > button:hover,
.mini-projects > button[aria-pressed=true] {
  background: var(--hover);
}
.project-glyph {
  width: 32px;
  height: 32px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  color: var(--accent);
}
.project-glyph svg {
  width: 20px;
  height: 20px;
}
.mini-projects strong {
  font-size: 12px;
  font-weight: 550;
  display: block;
  margin-bottom: 4px;
}
.mini-projects small {
  color: var(--muted);
  font-size: 10px;
}
.project-check {
  margin-left: auto;
  opacity: 0;
}
.mini-projects [aria-pressed=true] .project-check {
  opacity: 1;
}
.parts-panel {
  left: 16px;
  top: 137px;
  bottom: 78px;
  width: 228px;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.parts-open .mini-canvas-wrap {
  left: 235px;
}
.part-search {
  display: flex;
  align-items: center;
  padding: 0 11px;
  margin: 9px 10px 5px;
  background: var(--stage-bottom);
  border: 1px solid var(--line);
  border-radius: 7px;
  height: 34px;
  flex: none;
  gap: 8px;
  color: var(--muted);
}
.part-search svg {
  width: 14px;
  height: 14px;
}
.part-search input {
  width: 100%;
  min-width: 0;
  background: none;
  border: 0;
  color: var(--text);
  font-size: 11px;
}
.part-search input:focus-visible {
  outline: 0;
}
.part-search:focus-within {
  border-color: var(--line);
}
.parts-list {
  overflow: auto;
  padding: 4px 6px;
  flex: 1;
  min-height: 0;
  scrollbar-width: thin;
}
.part-group {
  font-size: 9px;
  color: var(--subtle);
  padding: 14px 9px 5px;
  letter-spacing: .04em;
}
.part-row {
  display: flex;
  gap: 2px;
  align-items: center;
  border-radius: 7px;
  margin: 2px 0;
}
.part-row.selected {
  background: var(--selected);
}
.part-row.is-hidden {
  opacity: .45;
}
.part-row:hover {
  background: var(--hover);
}
.part-select {
  flex: 1;
  min-width: 0;
  display: flex;
  gap: 8px;
  padding: 9px 7px;
  align-items: center;
  text-align: left;
  font-size: 11px;
  line-height: 1.5;
}
.part-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
  flex: none;
}
.part-row.selected .part-dot {
  background: var(--text);
}
.part-name {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.part-visibility {
  width: 26px;
  height: 30px;
  padding: 5px;
  color: var(--muted);
}
.part-visibility svg {
  width: 15px;
  height: 15px;
}
.part-actions {
  display: flex;
  gap: 4px;
  padding: 8px;
  border-top: 1px solid var(--line);
}
.part-actions button {
  flex: 1;
  padding: 8px;
  border-radius: 6px;
  background: var(--hover);
  font-size: 10px;
}
.part-actions button:hover {
  background: var(--hover);
}
.empty-search {
  padding: 18px;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.6;
}
.selection-chip {
  position: absolute;
  top: 78px;
  right: 16px;
  max-width: calc(100% - 270px);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 3px 3px 3px 11px;
  display: flex;
  gap: 8px;
  align-items: center;
  background: var(--surface);
  box-shadow: 0 3px 12px #0002;
  z-index: 4;
}
.selection-chip > span {
  font-size: 10px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.selection-chip .icon-button {
  width: 26px;
  height: 26px;
}
.selection-chip svg {
  width: 13px;
  height: 13px;
}
.dock {
  position: absolute;
  bottom: 17px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: 3px;
  padding: 5px;
  border: 1px solid var(--line);
  background: var(--panel);
  border-radius: 14px;
  box-shadow: 0 3px 16px #0003;
  backdrop-filter: blur(18px);
  z-index: 9;
}
.dock > button {
  position: relative;
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border-radius: 10px;
  color: var(--accent);
}
.dock > button:hover,
.dock > button[aria-expanded=true] {
  background: var(--hover);
  color: var(--text);
}
.dock > button.is-active:after {
  content: "";
  position: absolute;
  bottom: 3px;
  left: 15px;
  width: 6px;
  height: 2px;
  background: var(--accent);
  border-radius: 2px;
}
.dock-divider {
  height: 20px;
  width: 1px;
  background: #44464e;
  margin: 0 3px;
}
.tool-lane {
  position: absolute;
  bottom: 76px;
  left: 50%;
  transform: translateX(-50%);
  width: min(440px, calc(100% - 32px));
  z-index: 10;
}
.tool-panel {
  background: var(--panel);
  border: 1px solid var(--line);
  backdrop-filter: blur(22px);
  border-radius: 13px;
  box-shadow: 0 12px 40px #0005;
  animation: panel-in 150ms ease-out;
}
.range-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 15px;
}
.range-row > button {
  font-size: 10px;
  color: var(--accent);
  padding: 7px 0;
}
.range-row input[type=range] {
  min-width: 40px;
  flex: 1;
  width: 100%;
  accent-color: var(--accent);
  height: 20px;
}
.check-label {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 10px;
  color: var(--muted);
  margin-left: auto;
}
.check-label input {
  accent-color: var(--accent);
}
.check-label + .icon-button {
  margin-left: 0;
}
.segmented {
  display: flex;
  padding: 3px;
  gap: 3px;
  background: var(--stage-mid);
  border: 1px solid var(--line);
  border-radius: 9px;
}
.segmented button {
  padding: 8px 11px;
  border-radius: 6px;
  color: var(--muted);
  font-size: 11px;
  white-space: nowrap;
}
.segmented button:hover {
  color: var(--text);
}
.segmented button[aria-pressed=true] {
  background: var(--selected);
  color: var(--text);
  box-shadow: 0 1px 5px #0003;
}
.appearance-options,
.mini-view-modes {
  margin: 12px;
  justify-content: stretch;
}
.appearance-options button,
.mini-view-modes button {
  flex: 1;
}
.measure-content {
  padding: 16px;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.7;
}
.measure-name {
  display: block;
  color: var(--text);
  font-size: 11px;
  margin-bottom: 12px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.dimension-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}
.dimension-grid div {
  display: flex;
  flex-direction: column;
  gap: 3px;
  border-left: 1px solid var(--line);
  padding-left: 12px;
  font-family: Plex, monospace;
}
.dimension-grid span {
  font-size: 10px;
  color: var(--muted);
}
.dimension-grid strong {
  font-size: 17px;
  font-weight: 400;
  color: var(--text);
}
.measure-note {
  display: block;
  margin-top: 12px;
  color: var(--subtle);
  font-size: 10px;
}
.making-fields {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 13px 14px;
  padding: 14px 16px;
  max-height: min(340px, calc(100vh - 200px));
  overflow: auto;
  scrollbar-width: thin;
}
.making-fields label {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 10px;
  color: var(--muted);
}
.making-fields select,
.making-fields input {
  width: 100%;
  padding: 9px 10px;
  background: var(--stage-mid);
  border: 1px solid var(--line);
  border-radius: 7px;
  min-height: 35px;
  font-size: 11px;
  color: var(--text);
}
.wide-field {
  grid-column: 1/-1;
}
.intent-impact {
  color: var(--accent);
  font-size: 11px;
  line-height: 1.65;
  margin: 0;
}
.intent-status {
  font-size: 10px;
  color: var(--muted);
  padding-top: 3px;
}
.view-status {
  position: absolute;
  bottom: 20px;
  left: 16px;
  max-width: calc(50% - 160px);
  pointer-events: none;
  line-height: 1.6;
}
.view-status > span:first-child {
  display: block;
  font-family: Plex, monospace;
  font-size: 9px;
  letter-spacing: .08em;
  color: var(--muted);
}
.view-status > span:last-child {
  display: block;
  font-size: 9px;
  color: var(--muted);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.view-navigation {
  position: absolute;
  bottom: 20px;
  right: 16px;
  display: flex;
  align-items: center;
  gap: 7px;
  z-index: 6;
}
.mini-view-tools {
  display: flex;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: var(--panel);
}
.mini-view-tools .icon-button {
  width: 28px;
  height: 30px;
  border-radius: 8px;
}
.mini-view-tools svg {
  width: 14px;
  height: 14px;
}
#grid-toggle[aria-pressed=true] {
  color: var(--text);
}
.axis-views {
  position: relative;
  width: 50px;
  height: 48px;
  border-radius: 50%;
  background: var(--surface);
}
.axis-views button {
  position: absolute;
  display: grid;
  place-items: center;
  border: 1px solid #838da955;
  width: 21px;
  height: 21px;
  border-radius: 50%;
  font: 9px Plex, monospace;
  background: #253b65;
  color: #b6cdff;
}
.axis-views button:nth-child(1) {
  top: 0;
  left: 14px;
}
.axis-views button:nth-child(2) {
  bottom: 0;
  left: 0;
  background: #233f37;
  color: #b9dac7;
}
.axis-views button:nth-child(3) {
  bottom: 0;
  right: 0;
  background: #55313c;
  color: #f0bbce;
}
.axis-views button:hover {
  filter: brightness(1.4);
}
.mini-agent {
  position: relative;
  display: flex;
  flex-direction: column;
  min-width: 0;
  background: var(--bg);
  border-left: 1px solid var(--line);
  overflow: hidden;
}
.agent-collapsed .mini-agent {
  visibility: hidden;
}
.mini-agent-head {
  display: flex;
  gap: 9px;
  align-items: center;
  padding: 17px 12px 13px 17px;
  min-height: 67px;
  flex: none;
}
.mini-agent-head > div {
  flex: 1;
  min-width: 0;
}
.mini-agent-head strong {
  font-size: 12px;
  font-weight: 550;
}
.mini-agent-head > div > span {
  display: block;
  color: var(--subtle);
  font-size: 9px;
  margin-top: 4px;
}
.mini-agent-head .icon-button {
  width: 25px;
  height: 30px;
}
.mini-agent-head svg {
  width: 16px;
  height: 16px;
}
.mini-agent-icon {
  flex: none;
}
.mini-agent-ready {
  color: var(--muted);
  font-size: 10px;
  padding: 5px 19px 13px;
  line-height: 1.7;
  flex: none;
}
.mini-thread {
  flex: 1;
  min-height: 70px;
  overflow: auto;
  padding: 15px 19px 22px;
  scrollbar-width: thin;
  scrollbar-color: var(--line) transparent;
}
.mini-agent-empty {
  padding-top: 30px;
}
.mini-agent-empty > span {
  font: 8px Plex, monospace;
  color: var(--muted);
  letter-spacing: .08em;
  display: block;
  margin-bottom: 16px;
}
.mini-agent-empty > strong {
  font-size: 23px;
  font-weight: 450;
  letter-spacing: -.04em;
  line-height: 1.25;
  display: block;
  max-width: 230px;
  color: var(--text);
}
.mini-agent-empty > p {
  font-size: 11px;
  color: var(--muted);
  line-height: 1.8;
  margin: 16px 0 0;
  max-width: 220px;
}
.mini-agent-compose {
  padding: 12px 13px 15px;
  flex: none;
}
.mini-prompt-list {
  display: grid;
  gap: 5px;
  margin-bottom: 16px;
}
.mini-prompt-list > button {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  text-align: left;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: var(--field);
  min-height: 38px;
  align-items: center;
  padding: 9px 11px;
  font-size: 10px;
  color: var(--accent);
  line-height: 1.4;
}
.mini-prompt-list > button:hover,
.mini-prompt-list > button[aria-pressed=true] {
  border-color: var(--line);
  background: var(--selected);
  color: var(--text);
}
.mini-prompt-list > button > span:last-child {
  color: var(--muted);
}
.mini-context {
  font: 7px Plex, monospace;
  color: var(--muted);
  letter-spacing: .025em;
  padding: 0 5px 8px;
}
.mini-compose-trigger {
  display: flex;
  gap: 12px;
  align-items: center;
  justify-content: space-between;
  border: 1px solid var(--line);
  border-radius: 12px;
  min-height: 60px;
  width: 100%;
  padding: 13px;
  color: var(--muted);
  font-size: 11px;
}
.mini-compose-trigger:hover {
  border-color: var(--line);
  color: var(--text);
}
.mini-compose-trigger [data-icon] {
  background: var(--text);
  border-radius: 7px;
  padding: 5px;
  color: var(--bg);
}
.mini-compose-trigger svg {
  width: 13px;
  height: 13px;
}
.mini-message {
  margin-bottom: 24px;
  font-size: 12px;
  line-height: 1.75;
}
.mini-message-by {
  display: block;
  font-size: 10px;
  color: var(--text);
  margin-bottom: 7px;
  font-weight: 550;
}
.mini-message-user {
  margin-left: 15px;
  background: var(--surface);
  border-radius: 13px 13px 3px 13px;
  padding: 12px 14px;
}
.mini-message-user .mini-message-by {
  display: none;
}
.mini-message p {
  margin: 0;
  color: var(--text);
}
.mini-message-user p {
  color: var(--text);
}
.mini-activity {
  font-size: 9px;
  display: block;
  color: var(--muted);
  line-height: 1.6;
  margin-bottom: 12px;
  padding: 9px 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
}
.message-parts {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-top: 11px;
}
.message-parts button {
  padding: 5px 7px;
  border: 1px solid var(--line);
  border-radius: 5px;
  color: var(--accent);
  font-size: 9px;
}
.message-parts button:hover {
  background: var(--hover);
  color: var(--text);
}
.mini-ecad {
  position: absolute;
  inset: 64px 16px 78px;
  border: 1px solid var(--line);
  border-radius: 10px;
  overflow: hidden;
  background: var(--bg);
  touch-action: none;
}
.mini-ecad svg {
  width: 100%;
  height: 100%;
  stroke: none;
  display: block;
}
.mini-ecad .ecad-viewport {
  width: 100%;
  height: 100%;
  transform-origin: center;
}
.mini-ecad [data-part] {
  cursor: pointer;
}
.mini-ecad [data-part]:focus-visible {
  outline: 0;
  filter: brightness(1.7);
}
.ecad-active canvas {
  visibility: hidden;
}
.ecad-active ~ .workspace-nav .project-title {
  display: none;
}
.ecad-active ~ .workspace-nav .parts-trigger {
  margin-top: 4px;
}
.ecad-active ~ .selection-chip {
  top: 108px;
}
.ecad-active .mini-fallback {
  display: none;
}
@keyframes panel-in {
  from {
    opacity: 0;
    transform: translateY(5px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
@media (min-width: 1150px) {
  .workbench {
    grid-template-columns: minmax(0, 1fr) 310px;
  }
}
@media (max-width: 900px) {
  .view-status {
    max-width: 150px;
    bottom: 77px;
  }
  .view-status > span:last-child {
    display: none;
  }
  .view-navigation {
    bottom: 77px;
  }
  .selection-chip {
    top: 137px;
    max-width: calc(100% - 32px);
  }
  .workspace-nav {
    left: 12px;
  }
  .workspace-actions {
    right: 12px;
  }
  .mini-agent-empty > strong {
    font-size: 21px;
  }
  .parts-open .mini-canvas-wrap {
    left: 0;
  }
  .parts-panel {
    width: 228px;
    top: 137px;
    bottom: 76px;
  }
  .tool-lane {
    width: min(420px, calc(100% - 24px));
  }
  .mini-ecad {
    inset: 137px 12px 130px;
  }
}
@media (max-width: 680px) {
  .workbench,
  .workbench.agent-collapsed {
    grid-template-columns: minmax(0, 1fr);
  }
  .mini-agent {
    position: absolute;
    inset: 0;
    z-index: 30;
    width: 100%;
    border-left: 0;
    background: var(--bg);
  }
  .agent-collapsed .mini-agent {
    display: none;
  }
  .mini-agent-head {
    padding: 16px 18px;
  }
  .mini-agent-head .icon-button {
    width: 36px;
    height: 36px;
  }
  .mini-agent-head > div > span {
    font-size: 10px;
  }
  .mini-thread {
    padding: 8px 22px 18px;
  }
  .mini-agent-empty {
    padding-top: 18px;
  }
  .mini-agent-empty > strong {
    font-size: 27px;
    max-width: 280px;
  }
  .mini-agent-empty > p {
    max-width: 300px;
    font-size: 12px;
  }
  .mini-agent-compose {
    padding: 10px 16px 17px;
  }
  .mini-prompt-list > button {
    font-size: 11px;
    min-height: 40px;
  }
  .mini-compose-trigger {
    min-height: 48px;
  }
  .workspace-nav {
    top: 13px;
    gap: 7px;
  }
  .library-trigger {
    font-size: 10px;
    min-height: 34px;
    padding: 0 9px;
    gap: 6px;
  }
  .library-trigger > span:last-child {
    margin-left: 2px;
    padding-left: 5px;
  }
  .project-title {
    font-size: 9px;
    max-width: 205px;
  }
  .parts-trigger {
    min-height: 34px;
    font-size: 10px;
  }
  .workspace-actions {
    top: 13px;
    gap: 4px;
  }
  .workspace-actions > [data-view-action=reset] {
    display: none;
  }
  .workspace-actions .icon-button {
    width: 31px;
    height: 34px;
  }
  .agent-toggle {
    width: 37px;
    height: 37px;
    margin-left: 1px;
    border-radius: 10px;
  }
  .agent-toggle img {
    width: 24px;
    height: 24px;
  }
  .selection-chip {
    top: 118px;
    right: 12px;
    max-width: calc(100% - 24px);
  }
  .view-status {
    left: 13px;
    bottom: 78px;
  }
  .view-navigation {
    right: 12px;
    bottom: 77px;
  }
  .dock {
    bottom: 16px;
    gap: 3px;
    padding: 5px;
  }
  .dock > button {
    width: 38px;
    height: 38px;
  }
  .parts-panel {
    top: 124px;
    left: 12px;
    width: calc(100% - 24px);
    bottom: 76px;
    max-width: 330px;
  }
  .parts-panel .part-select {
    padding: 11px 9px;
  }
  .project-library {
    left: 12px;
    top: 54px;
    width: calc(100% - 24px);
    max-width: 290px;
  }
  .tool-lane {
    bottom: 77px;
  }
  .panel-heading {
    min-height: 42px;
    padding-left: 13px;
  }
  .panel-heading strong {
    font-size: 11px;
  }
  .range-row {
    gap: 9px;
    padding: 12px;
  }
  .range-row > button {
    font-size: 9px;
  }
  .making-fields {
    padding: 11px 13px;
    gap: 10px;
    max-height: calc(100vh - 190px);
  }
  .segmented button {
    padding: 8px 10px;
    font-size: 10px;
  }
  .mini-ecad {
    inset: 118px 10px 135px;
  }
  .mini-context {
    font-size: 8px;
  }
  .mini-message {
    font-size: 12px;
  }
}
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
    scroll-behavior: auto !important;
  }
}
.ecad-sheet {
  min-width: 100%;
  min-height: 100%;
}
.ecad-sheet svg {
  width: 100%;
  height: 100%;
  display: block;
  font-family:
    Inter,
    system-ui,
    sans-serif;
  user-select: none;
}
.ecad-sheet text {
  pointer-events: none;
}
.ecad-heading {
  font-family: ui-monospace, monospace;
  font-size: 12px;
  letter-spacing: 1px;
  fill: var(--muted);
}
.ecad-note {
  font-size: 11px;
  fill: var(--muted);
}
.ecad-dimension {
  stroke: var(--muted);
  stroke-width: 1;
  fill: none;
}
.sch-component {
  fill: var(--surface);
  stroke: var(--muted);
  stroke-width: 1.2;
}
.sch-ref {
  fill: var(--cad-blue);
  font-family: ui-monospace, monospace;
  font-size: 10px;
}
.sch-name {
  fill: var(--text);
  font-size: 13px;
  font-weight: 600;
}
.sch-detail {
  fill: var(--muted);
  font-size: 10px;
}
.sch-net {
  fill: var(--cad-blue);
  font-size: 10px;
}
.sch-wire {
  stroke: var(--cad-blue);
  stroke-width: 1.3;
  fill: none;
}
.sch-proposed {
  stroke-dasharray: 5 4;
}
.sch-junction {
  fill: var(--cad-blue);
}
[data-ecad-part] {
  cursor: pointer;
  outline: none;
}
[data-ecad-part]:hover > .pcb-component,
[data-ecad-part]:focus-visible > .pcb-component,
[data-ecad-part].ecad-selected > .pcb-component {
  stroke: #c6e5ff;
  stroke-width: 3;
}
[data-ecad-part]:hover > .sch-component,
[data-ecad-part]:focus-visible > .sch-component,
[data-ecad-part].ecad-selected > .sch-component {
  stroke: var(--cad-highlight);
  stroke-width: 3;
  fill: var(--hover);
}
[data-ecad-part].ecad-selected > .pcb-heatsink {
  stroke: #c6e5ff;
  stroke-width: 3;
}
.pcb-drafting-bg {
  fill: #20262d;
}
.pcb-grid-minor {
  fill: none;
  stroke: #697687;
  stroke-opacity: .09;
  stroke-width: .7;
}
.pcb-grid-major {
  fill: none;
  stroke: #8797ac;
  stroke-opacity: .25;
  stroke-width: .8;
}
.pcb-board-outline {
  fill: none;
  stroke: #a3b2c4;
  stroke-width: 1.8;
}
.pcb-courtyard {
  fill: none;
  stroke: #88728b;
  stroke-width: 1;
}
.pcb-component {
  fill: transparent;
  stroke: #88728b;
}
.pcb-fabrication {
  fill: none;
  stroke: #aaa9ac;
  stroke-width: .7;
}
.pcb-trace {
  fill: none;
  stroke: #e99384;
  stroke-opacity: .72;
}
.pcb-pad {
  fill: #ed9687;
  stroke: none;
}
.pcb-via {
  fill: #20262d;
  stroke: #cd8c80;
  stroke-width: .8;
}
.pcb-mount {
  fill: none;
  stroke: #a6b8cc;
  stroke-width: 1.4;
}
.pcb-hole {
  fill: #a6b8cc;
}
.pcb-drill {
  fill: #20262d;
}
.pcb-back-pad,
.pcb-back-key {
  fill: #80a9d8;
}
.pcb-bottom {
  stroke: #80a9d8;
  stroke-dasharray: 5 4;
}
.pcb-reference {
  fill: #e0e3e8;
  font-family: ui-monospace, monospace;
  font-size: 10px;
}
.pcb-text {
  fill: #d9dee6;
  font-size: 11px;
  paint-order: stroke;
  stroke: #20262d;
  stroke-width: 3;
  stroke-linejoin: round;
}
.pcb-small {
  fill: #b9c2ce;
  font-size: 9px;
  paint-order: stroke;
  stroke: #20262d;
  stroke-width: 2;
  stroke-linejoin: round;
}
.pcb-origin {
  stroke: #8298b2;
  stroke-width: .7;
}
.pcb-coordinate {
  fill: #8298b2;
  font-family: ui-monospace, monospace;
  font-size: 9px;
}
.pcb-heatsink {
  fill: none;
  stroke: #819097;
  stroke-dasharray: 5 4;
  opacity: .6;
  pointer-events: stroke;
}
.atlas-pcb .ecad-heading {
  fill: #c6ced7;
}
.atlas-pcb .ecad-note {
  fill: #99a8ba;
}
.atlas-pcb .ecad-dimension {
  stroke: #8291a2;
}
.mini-ecad {
  overflow: auto;
  cursor: grab;
  scrollbar-width: thin;
}
.mini-ecad:active {
  cursor: grabbing;
}
.mini-ecad svg {
  fill: initial;
}
.reveal-model {
  padding: 10px 13px;
  margin-top: 15px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--text);
  font-size: 11px;
  background: var(--selected);
}
@media (min-width: 901px) {
  .parts-open .tool-lane,
  .parts-open .dock {
    left: calc(50% + 117.5px);
  }
  .parts-open .tool-lane {
    width: min(440px, calc(100% - 265px));
  }
}
.hover-hint {
  position: absolute;
  z-index: 8;
  pointer-events: none;
  max-width: 210px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 10px;
  background: var(--panel);
  color: var(--text);
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 7px 10px;
  box-shadow: 0 3px 12px #0003;
}
.touch-toggle {
  display: none;
}
.touch-help {
  display: none;
}
@media (hover: hover) {
  .dock > button::before {
    content: attr(aria-label);
    position: absolute;
    bottom: 49px;
    left: 50%;
    transform: translate(-50%, 4px);
    padding: 7px 9px;
    border-radius: 6px;
    font-size: 10px;
    white-space: nowrap;
    background: var(--hover);
    color: var(--text);
    border: 1px solid var(--line);
    box-shadow: 0 4px 12px #0003;
    opacity: 0;
    pointer-events: none;
    transition: opacity 100ms, transform 100ms;
  }
  .dock > button:hover::before,
  .dock > button:focus-visible::before {
    opacity: 1;
    transform: translate(-50%, 0);
  }
  .dock > button[aria-expanded=true]::before {
    display: none;
  }
}
@media (max-width: 680px), (any-pointer: coarse) {
  .workbench:not(.touch-interactive) #mini-canvas {
    touch-action: pan-y !important;
  }
  .mini-canvas-wrap {
    touch-action: pan-y;
  }
  .touch-toggle {
    display: block;
    position: absolute;
    bottom: 81px;
    left: 13px;
    z-index: 7;
    font-size: 11px;
    color: var(--accent);
    border: 1px solid var(--line);
    background: var(--surface);
    padding: 8px 10px;
    border-radius: 7px;
    min-height: 44px;
  }
  .touch-toggle[aria-pressed=true] {
    background: var(--text);
    color: var(--bg);
  }
  .view-status {
    display: none;
  }
  .selection-chip {
    top: 127px;
  }
  .hover-hint {
    display: none !important;
  }
  .ecad-active ~ .touch-toggle {
    display: none;
  }
}
.has-conversation:not(.show-prompts) .mini-prompt-list {
  display: none;
}
@media (max-width: 680px) {
  .message-parts button {
    font-size: 10px;
    min-height: 30px;
    padding: 6px 8px;
  }
}
@media (max-width: 680px) {
  .tool-open .view-navigation,
  .tool-open .touch-toggle,
  .tool-open .selection-chip {
    display: none;
  }
}
.mini-ecad {
  touch-action: pan-x pan-y;
}

/* Paper drafting colors keep technical layers legible without changing their geometry. */
[data-theme=light] .pcb-drafting-bg,[data-theme=light] .pcb-via,[data-theme=light] .pcb-drill{fill:#f5f5f3}
[data-theme=light] .pcb-text,[data-theme=light] .pcb-small{stroke:#f5f5f3;fill:#454951}
[data-theme=light] .pcb-reference{fill:#383c43}
[data-theme=light] .pcb-grid-minor{stroke:#66707e;stroke-opacity:.12}
[data-theme=light] .pcb-grid-major{stroke:#66707e;stroke-opacity:.25}
[data-theme=light] .pcb-board-outline,[data-theme=light] .pcb-mount{stroke:#596675}
[data-theme=light] .pcb-hole{fill:#596675}
[data-theme=light] .pcb-fabrication{stroke:#66676e}
[data-theme=light] .pcb-trace{stroke:#a3493d}
[data-theme=light] .pcb-pad{fill:#b75d4d}
[data-theme=light] .pcb-back-pad,[data-theme=light] .pcb-back-key{fill:#3e6a9e}
[data-theme=light] .pcb-bottom{stroke:#3e6a9e}
[data-theme=light] .atlas-pcb .ecad-heading{fill:var(--text)}
[data-theme=light] .atlas-pcb .ecad-note{fill:var(--muted)}
[data-theme=light] [data-ecad-part]:is(:hover,:focus-visible,.ecad-selected)>.pcb-component,[data-theme=light] [data-ecad-part].ecad-selected>.pcb-heatsink{stroke:#345b98}

/* Small UI text stays readable without changing the model or control layout. */
.muted,.project-title,.mini-projects small,.part-group,.measure-note,.view-status>span:first-child,.view-status>span:last-child,.mini-agent-head>div>span,.mini-agent-ready,.mini-agent-empty>span,.mini-activity,.intent-status,.making-fields label,.dimension-grid span{font-size:11px}
.mini-context{font-size:10px;line-height:1.6}
.library-trigger,.parts-trigger,.panel-heading strong,.part-select,.measure-content,.mini-agent-empty>p,.mini-prompt-list>button{font-size:12px}
.range-row>button,.part-actions button,.segmented button,.intent-impact,.hover-hint{font-size:11px}
.panel-heading>.icon-button,.mini-agent-head .icon-button{width:40px;height:40px;flex-shrink:0}
.panel-heading{padding-block:0;flex-shrink:0}.part-group{padding-top:8px}
.mini-agent-head{padding-block:10px}.mini-agent-empty{padding-top:0}.mini-agent-empty>span{margin-bottom:10px}.mini-prompt-list{margin-bottom:10px}
.part-search{height:40px}.part-search input{font-size:12px}.part-search:focus-within{border-color:var(--signal);box-shadow:0 0 0 1px var(--signal)}
.dimension-grid strong,.panel-heading output,.making-fields input{font-variant-numeric:tabular-nums}
@media(max-width:680px){.panel-heading>.icon-button,.mini-agent-head .icon-button{width:44px;height:44px}.mini-prompt-list>button{min-height:44px}.mini-agent-head{padding-block:12px}.mini-agent-empty{padding-top:10px}}

/* Phone controls use separate rows so every action remains easy to tap. */
@media (max-width: 680px) {
  .library-trigger, .parts-trigger, .agent-toggle {min-height:44px}
  .agent-toggle {width:44px;height:44px}
  .project-title {max-width:calc(100vw - 100px)}
  .project-library {top:64px;max-height:calc(100% - 76px);overflow:auto}
  .parts-panel {top:148px}
  .part-select, .part-visibility, .part-actions button {min-height:44px}
  .part-visibility {width:44px;flex:none;display:grid;place-items:center}
  .part-search input, .making-fields input, .making-fields select {font-size:16px}
  .making-fields label {min-width:0}
  .making-fields input, .making-fields select {min-height:44px}
  .selection-chip {top:148px}
  .selection-chip .icon-button {width:44px;height:44px}
  .dock {bottom:12px;width:min(304px,calc(100% - 4px));gap:0;padding:3px}
  .dock > button {flex:1;min-width:0;height:44px}
  .dock-divider {display:none}
  .view-navigation {bottom:74px;left:3px;right:3px;justify-content:center;gap:4px}
  .mini-view-tools .icon-button {width:44px;height:44px}
  .axis-views {display:flex;width:auto;height:44px;border-radius:9px}
  .axis-views button {position:static;width:44px;height:44px;flex:none;font-size:11px}
  .touch-toggle {bottom:130px;left:12px;max-width:110px}
  .touch-help {display:block;position:absolute;left:116px;right:12px;bottom:130px;min-height:44px;align-content:center;color:var(--muted);font-size:10px;line-height:1.6;pointer-events:none}
  .tool-open .touch-help, .ecad-active ~ .touch-help {display:none}
  .mini-ecad {inset:148px 10px 126px}
  .segmented button, .range-row > button {min-height:44px}
  .range-row input[type=range] {height:44px}
}
