body.native-workspace{grid-template-rows:25px 25px 0 0 minmax(0,1fr) 0 24px;background:#ccc;font:12px Tahoma,Arial,sans-serif}.native-workspace .title-bar{padding:0 7px;background:#266a93}.title-bar strong{letter-spacing:0}.title-bar .local-indicator{font-size:9px}.native-workspace .command-bar,.native-workspace .document-strip,.native-workspace .palette-ribbon,.native-workspace .viewbar,.native-workspace .below,.native-workspace #textureActions{display:none}.native-workspace.quick-dock{grid-template-rows:25px 25px 36px 0 minmax(0,1fr) 36px 24px}.native-workspace.quick-dock .command-bar,.native-workspace.quick-dock .palette-ribbon{display:flex}.native-workspace .workspace{grid-template-rows:minmax(0,1fr)}.native-workspace .menu-bar{overflow:visible;padding:0 3px;background:#d4d0c8;border-bottom:2px groove white}.menu summary{padding:4px 12px}.menu-popup{top:24px;background:#d4d0c8;min-width:230px;border:2px outset #eee;border-radius:0;box-shadow:3px 3px 0 #0004}.menu-popup button{padding:5px 9px;font-size:12px;border-radius:0}.menu-popup button:hover{background:#17699c;color:white}.menu-popup [data-interface-kind=native-only]{color:#777}.menu-popup [data-interface-kind=native-only]:after{content:' ◇';font-size:9px}.native-window-button{margin-left:auto;padding:1px 9px}.native-workspace button,.native-workspace input,.native-workspace select{border-radius:0}.native-workspace button{border:1px outset #eee;background:#d4d0c8}.native-workspace button:hover{background:#e9e6e0}.native-workspace input,.native-workspace select{background:white;border:1px inset #aaa}.native-workspace .tool-window{border:2px outset #eee;border-radius:0;background:#d4d0c8;box-shadow:3px 3px 0 #0003}.native-workspace .window-title{height:23px;background:#28739c;padding:0 3px 0 6px;font-size:11px}.window-title button{font-size:13px!important;padding:0 5px!important;background:transparent!important;border:0!important;color:white}.native-workspace .window-content{padding:7px;background:#d4d0c8}.window-menubar{display:flex;gap:1px;padding:1px;border-bottom:1px solid #999;flex-shrink:0}.window-menubar button{border:0!important;padding:3px 8px;font-size:11px}.native-workspace .weave-window{width:560px;height:530px;left:28px;top:45px;bottom:auto}.native-workspace .weave-window>.window-content{display:flex;flex-direction:column;overflow:hidden;flex:1}.engine-weave-controls{display:none!important}.native-weave-body{display:flex;flex:1;min-height:0;gap:5px}#nativeWeaveTools{display:grid;grid-template-columns:repeat(3,30px);gap:2px;align-content:start;flex-shrink:0}#nativeWeaveTools button{width:30px;height:29px;padding:2px}#nativeWeaveTools img{max-width:24px;max-height:24px;image-rendering:pixelated}#nativeWeaveTools button.active{border:2px inset #aaa;background:#b7c8d2}.native-weave-grid{display:flex;flex-direction:column;min-width:0;min-height:0;flex:1}#weaveScroll{position:relative;overflow:auto;flex:1;min-height:150px;background:#888;border:2px inset #eee}#weaveExtent{position:relative;min-width:100%;min-height:100%}#fullWeaveCanvas{position:sticky;top:0;left:0;display:block;cursor:crosshair;image-rendering:pixelated}#nativeDraftPreview{height:65px;max-width:100%;image-rendering:pixelated;background:white}#fullWeaveCoordinates{font-size:10px;min-height:20px;padding:3px}.native-workspace .yarn-window{width:345px;right:18px;top:30px}.native-workspace .inspector-window{width:300px;left:45px;top:60px}.native-workspace [data-window=thread]{width:430px;left:65px;top:75px}.native-workspace [data-window=colours]{width:360px;left:120px;top:80px}.native-workspace [data-window=blanket]{width:680px;height:520px;left:140px;top:60px}.native-workspace [data-window=technical]{width:580px;height:470px;left:100px;top:70px}.native-workspace [data-window=coverage]{width:720px;height:550px;left:80px;top:45px}.native-workspace [data-window=reference]{width:430px;left:160px;top:90px}#colourEditorGrid{display:grid;grid-template-columns:repeat(8,1fr);gap:2px}#colourEditorGrid button{height:28px;font-size:10px}.native-data-table{width:100%;border-collapse:collapse;background:white;font-size:11px;margin:5px 0}.native-data-table td{border:1px solid #aaa;padding:5px}#coverageList{display:flex;flex-direction:column;gap:2px}#coverageList button{text-align:left;padding:6px}#coverageList small{display:block;font-size:10px;color:#666;margin-top:3px}#blanketCards{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}#blanketCards canvas{max-width:100%;height:auto;display:block}#blanketCards article{border:1px solid #aaa;padding:4px}.native-export-controls{display:flex;flex-wrap:wrap;gap:3px;border-top:1px solid #999;padding-top:5px}.native-export-controls select{width:100%}.native-workspace footer{background:#d4d0c8;color:#333;gap:12px;overflow:hidden;white-space:nowrap}.native-workspace footer #status{flex:1}.native-workspace footer #renderInfo{margin:0}.native-workspace dialog{border:2px outset #eee;border-radius:0;background:#d4d0c8;padding:14px}.native-workspace dialog h2{font-size:16px}#nativeWindowList{display:grid;grid-template-columns:1fr 1fr;gap:5px}#nativePrintImage{max-width:100%;max-height:65vh}#nativeFabricBrowser select{width:100%}.native-workspace .minimized{height:27px!important}.native-workspace .primary{background:#266a93;color:white}#nativeTitleArticle{font-size:11px;letter-spacing:0}#nativeUnavailable{background:#fff2c6;padding:9px;line-height:1.5}.native-workspace #yarnWindow .window-content{padding:6px}.native-workspace .yarn-editor-palette{grid-template-columns:repeat(13,1fr)}@media(max-width:1280px){.native-workspace .weave-window{width:510px;height:480px}.native-workspace .yarn-window{width:320px}.native-workspace footer #physical{max-width:220px;overflow:hidden}}@media print{body.native-workspace{display:block;height:auto;overflow:visible;background:white}body>*{display:none!important}#nativePrintDialog[open]{display:block!important;position:static;border:0;background:white;max-width:none;width:100%;box-shadow:none}#nativePrintDialog .dialog-actions{display:none}#nativePrintImage{max-height:none;width:100%}dialog::backdrop{display:none}}
.weave-native-layout{display:flex;flex:1;min-height:0;gap:5px}.weave-grid-side{display:flex;flex-direction:column;min-width:0;min-height:0;flex:1}.weave-grid-options{display:flex;align-items:center;gap:5px;flex-shrink:0}.weave-grid-options label{display:flex;align-items:center;gap:4px;margin:3px 0}.weave-grid-options select{margin:0!important;width:auto!important}#draftPreviewBar{flex-shrink:0;height:57px}
.native-workspace>.title-bar{grid-row:1}.native-workspace>.menu-bar{grid-row:2}.native-workspace>.command-bar{grid-row:3}.native-workspace>.document-strip{grid-row:4}.native-workspace>.studio-stage{grid-row:5}.native-workspace>.palette-ribbon{grid-row:6}.native-workspace>footer{grid-row:7}
@media print{#nativePrintDialog>button{display:none!important}}
.native-workspace #advancedUtilitiesDialog,.native-workspace #advancedBlanketDialog{background:#d4d0c8!important;color:#20282f!important;border:2px outset #eee!important;border-radius:0!important;padding:16px!important}.native-workspace #advancedUtilitiesDialog pre{background:#f7f7f1!important;color:#20282f!important;border:1px inset #aaa}.native-workspace #advancedUtilitiesDialog [role=alert]{color:#a02828!important}.native-workspace #advancedBlanketGrid article{background:#e1ded8}.native-workspace #advancedEffectsDialog #effectFields{display:grid;grid-template-columns:1fr 1fr;gap:8px}.native-workspace #advancedEffectsDialog #effectFields>.note{grid-column:1/-1}#effectStatus{color:#934421;min-height:20px}#geometryDialog{max-height:85vh;overflow:auto}
#advancedEffectsDialog{max-height:calc(100vh - 24px);overflow:auto}#advancedEffectsDialog #effectCanvas{max-height:45vh}.native-workspace #advancedEffectsDialog[data-tool=drape] #effectFields{grid-template-columns:repeat(3,minmax(0,1fr))}#advancedEffectsDialog h2{margin-bottom:8px}#advancedEffectsDialog p{margin:6px 0}
#cardWorkbenchDialog{max-height:calc(100vh - 24px);overflow:auto}#cardBitmapViewport{height:260px;overflow:auto;border:2px inset #eee;background:#888}#cardBitmap{display:block;image-rendering:pixelated;max-width:none}#cardLayoutInfo{white-space:pre-wrap;max-height:160px;overflow:auto;background:#f7f7f1;font-size:10px}#cardStatus{font-size:11px;line-height:1.5;color:#934421}#cardWorkbenchDialog .dialog-actions{flex-wrap:wrap}
#cardAuditInfo{white-space:pre-wrap;max-height:230px;overflow:auto;background:#f7f7f1;font-size:10px}#referenceFinishInfo{font-size:10px;line-height:1.5}#referenceFinish button{margin:3px 1px;font-size:10px}
.native-workspace #threadWindow{width:620px;overflow:hidden;max-height:calc(100% - 16px)}#threadWindow>.window-content{flex:1;min-height:0;overflow:auto}#threadAuthoring{font-size:11px}#threadAuthoring .ta-axis{background:#e1ded8;padding:7px}#threadAuthoring button{font-size:10px}#threadTextEntry{margin-top:9px;border-top:1px solid #999;padding-top:5px}#textronicToolbox{max-height:90vh;overflow:auto}#texToolGroups{display:grid;grid-template-columns:1fr 1fr;gap:7px}#texToolGroups fieldset{min-width:0;border:1px solid #999}#texToolGroups button{display:block;width:100%;text-align:left;margin:3px 0}#texToolInventory>div{border-bottom:1px solid #aaa;padding:7px}#texToolInventory strong,#texToolInventory small{display:block;margin:2px 0}#texToolInventory span{font-size:10px;color:#76512b}#weaveGeneratorDialog{width:620px;max-height:90vh;overflow:auto}
#yarnEditorPalette button,#colourEditorGrid button{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;min-width:0}

#pegPlanDialog { width: max-content; max-width: calc(100vw - 32px); overflow: auto; }
#pegPlanDialog input { width: 85px; }
#pegGrid button { min-width: 24px; min-height: 22px; padding: 1px 3px; }
#pegGrid button[aria-pressed="true"] { background: #245b78; color: white; }

/* The design workflow stays visible while the full canvas fills the remaining space. */
body.native-workspace {
  grid-template-rows: 25px 25px auto 0 minmax(0,1fr) 0 24px;
}
body.native-workspace.quick-dock {
  grid-template-rows: 25px 25px auto 36px minmax(0,1fr) 36px 24px;
}
.native-workspace.quick-dock > .command-bar { grid-row: 4; }
.studio-tools {
  grid-row: 3;
  display: flex;
  gap: 0;
  overflow-x: auto;
  padding: 7px 10px;
  background: #f4f7fa;
  border-bottom: 1px solid #b9c9d5;
}
.studio-tool-group {
  display: grid;
  grid-auto-flow: column;
  grid-template-rows: auto auto;
  align-content: start;
  gap: 4px;
  padding: 0 9px;
  border-right: 1px solid #d2dbe3;
  flex: 0 0 auto;
}
.studio-tool-group:first-child { padding-left: 0; }
.studio-tool-group:last-child { border: 0; }
.studio-tool-group > span {
  grid-column: 1 / span 3;
  grid-row: 1;
  font-size: 11px;
  font-weight: 700;
  color: #3b5466;
}
.studio-tool-group > button {
  grid-row: 2;
  white-space: nowrap;
  min-height: 28px;
  padding: 4px 8px;
  border: 1px solid #bdcbd6;
  background: white;
  border-radius: 3px;
}
.studio-tool-group > button:hover { background: #e8f2f9; }
.studio-tool-group > .studio-primary { background: #245b78; border-color: #245b78; color: white; }
.studio-tool-group > .studio-primary:hover { background: #1a4a65; }
@media (max-width: 1050px) {
  .studio-tools { padding-inline: 6px; }
  .studio-tool-group { padding-inline: 5px; }
  .studio-tool-group > button { padding-inline: 5px; }
}

.native-workspace #threadWindow { width: 800px; max-height: calc(100% - 16px); }
#threadAuthoring { padding: 0; border: 0; background: transparent; }
.ta-common { display: flex; flex-wrap: wrap; gap: 2px; margin-bottom: 6px; }
.ta-axes { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 10px; align-items: start; }
#threadAuthoring .ta-axis {
  margin: 0;
  border: 1px solid #becbd5;
  background: #f7f9fb;
  padding: 9px;
  min-width: 0;
}
.ta-axis > strong { color: #1c4d68; font-size: 14px; }
.ta-axis-setup { display: flex; flex-wrap: wrap; gap: 8px; margin: 6px 0; }
.ta-axis-setup label { display: flex; align-items: center; gap: 4px; }
.ta-options { margin-top: 6px; border-top: 1px solid #c8d3dc; padding-top: 5px; }
.ta-options summary { font-weight: 600; cursor: pointer; color: #345368; padding: 4px 0; }
#threadAuthoring .ta-status { margin: 6px 0 0; }
#threadAuthoring .ta-status:empty { display: none; }
@media (max-width: 740px) {
  .ta-axes { grid-template-columns: minmax(0,1fr); }
}

#textronicToolbox { background: #f2f6fa; border: 1px solid #bacbd8; }
#texToolGroups fieldset { border: 1px solid #c7d6e0; border-radius: 4px; background: #fff; }
#texToolGroups legend { color: #245b78; font-weight: 700; padding-inline: 5px; }
#texToolGroups button { background: #f5f8fb; border: 1px solid #d6e0e8; }
#texToolGroups button:hover { background: #e3eff8; border-color: #80acc8; }

#nativeDraftDialog > label { display: grid; gap: 5px; margin-top: 10px; }
#nativeDraftText { width: 100%; resize: vertical; }
#pegRangeTools { margin-top: 8px; }
#pegRangeTools summary { cursor: pointer; font-weight: 600; }

.studio-tool-group > .studio-tool-heading {
  grid-column: 1 / -1;
  grid-row: 1;
  justify-self: start;
  min-height: 0;
  padding: 1px 4px;
  border: 0;
  color: #315568;
  background: transparent;
  font-size: 11px;
  font-weight: 700;
}
.studio-tool-heading span { color: #527589; }
#textronicToolbox {
  width: min(920px, calc(100vw - 32px));
  max-height: calc(100dvh - 36px);
  padding: 16px;
}
.tex-tools-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}
.tex-tools-head h2 { margin: 0; }
.tex-tool-search { display: grid; gap: 5px; margin: 12px 0; font-weight: 700; }
.tex-tool-search input { width: 100%; padding: 8px 10px; font-weight: 400; }
.tex-tools-body {
  display: grid;
  grid-template-columns: 158px minmax(0,1fr);
  gap: 12px;
}
#texToolSections {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 3px;
  align-self: start;
  padding: 4px;
  border: 0;
  background: #e5eef4;
  border-radius: 4px;
}
#texToolSections button {
  text-align: left;
  padding: 7px 8px;
  border: 1px solid transparent;
  background: transparent;
  border-radius: 3px;
}
#texToolSections button:hover { background: #f5f9fb; }
#texToolSections button[aria-pressed="true"] { background: #245b78; color: #fff; }
#texToolGroups {
  display: grid;
  align-content: start;
  align-items: start;
  grid-template-columns: repeat(auto-fit,minmax(min(234px,100%),1fr));
  max-height: min(55vh, 530px);
  overflow: auto;
  padding: 2px;
}
#texToolGroups button { min-height: 30px; }
#texReference { border-top: 1px solid #bdcbd6; padding-top: 9px; margin-top: 10px; }
#texReference summary { cursor: pointer; }
#texReference > label { display: block; margin-top: 8px; }
@media (max-width: 640px) {
  .tex-tools-body { grid-template-columns: minmax(0,1fr); }
  #texToolSections { flex-direction: row; overflow-x: auto; }
  #texToolSections button { white-space: nowrap; }
  #texToolGroups { max-height: 48vh; }
}

.show-graphical #weaveWindow .window-title { pointer-events:none; cursor:default; }
.show-graphical #weaveWindow .window-title button { visibility:hidden; }
#activeDesignTools {
  position: absolute;
  inset: 0 0 0 auto;
  width: 192px;
  padding: 12px 10px;
  overflow: auto;
  background: #f0f5f8;
  border-left: 1px solid #acbfce;
}
#activeDesignTools h2 { margin: 0 0 10px; font-size: 14px; }
#activeDesignTools section { border-top: 1px solid #ccdae3; padding: 7px 0; }
#activeDesignTools p { margin: 3px 0 6px; color: #486173; }
#activeDesignTools button { margin: 0 3px 3px 0; }
.studio-tool-group [data-show-mode][aria-pressed="true"] {
  background: #245b78; color: white; border-color: #245b78;
}
#repeatFrame { position:absolute; border:2px solid #c33232; z-index: 2; pointer-events:none; }
.hide-design-rulers .drawing { grid-template-columns: 0 minmax(0,1fr); grid-template-rows: 0 minmax(0,1fr); }
.hide-design-rulers :is(#unitCorner,#topRuler,#leftRuler,#bar) { visibility:hidden; }
#graphicDraftDialog { max-width: calc(100vw - 36px); }
#draftGraphGrid button[aria-pressed="true"] { color:white; background:#245b78; }
#numericPegEntry textarea { width:100%; display:block; margin:5px 0; }

#activeDesignTools > section { flex: 0 0 auto; overflow: visible; }
#activeDesignTools[hidden] { display: none; }
@media (max-width: 1350px) {
  .studio-tools { padding-inline: 6px; }
  .studio-tool-group { padding-inline: 6px; }
  .studio-tool-group > button { padding-inline: 6px; }
}

/* Graphical desk: full design canvas, side tools and a lower-right weave editor. */
.show-graphical .studio-stage {
  --left-tools: 115px;
  --right-tools: clamp(288px,27vw,356px);
  --bottom-tools: 132px;
  --weave-dock-height: clamp(196px,33vh,246px);
}
.show-graphical .studio-stage > .workspace {
  margin-left: var(--left-tools);
  margin-right: var(--right-tools);
  height: calc(100% - var(--bottom-tools));
}
.show-graphical #weaveWindow {
  z-index: 5 !important;
  box-shadow: none;
}
#graphicalLeft,#activeDesignTools {
  position: absolute;
  top: 0;
  bottom: var(--bottom-tools);
  padding: 9px 8px;
  overflow: auto;
  border: 1px solid #acbfce;
  background: #edf3f7;
}
#graphicalLeft { left: 0; width: var(--left-tools); }
#activeDesignTools { right:0; width:var(--right-tools); bottom:calc(var(--bottom-tools) + var(--weave-dock-height)); }
#graphicalLeft[hidden],#activeDesignTools[hidden],#graphicalBottom[hidden] { display:none; }
#graphicalLeft h2,#activeDesignTools h2 { margin:0 0 7px; font-size:14px; }
#graphicalLeft h3,#activeDesignTools h3 { margin:0 0 4px; font-size:12px; }
#graphicalLeft > section,#activeDesignTools > section { flex:0 0 auto; padding:8px 0 0; overflow:visible; }
#graphicalLeft section { border-top:1px solid #ccdae3; margin-top:9px; }
#graphicalLeft section p { margin:3px 0 6px; color:#486173; }
#graphicalLeft section button { width:100%; margin-top:3px; padding:3px; }
#pegMiniGrid canvas { display:block; border:1px solid #97a7b2; }
#bookSwatches { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:5px; }
#bookSwatches button { display:grid; justify-items:center; gap:4px; padding:5px 2px; }
#bookSwatches button[aria-pressed="true"],#dockYarns button[aria-pressed="true"] { outline:2px solid #28739c; outline-offset:-2px; }
#bookSwatches canvas { border:1px solid #acbfce; max-width:100%; }
#activeDesignTools > button { flex-shrink:0; }
#graphicalBottom {
  position:absolute;
  inset:auto 0 0 0;
  height:var(--bottom-tools);
  display:grid;
  grid-template-columns: minmax(145px,1.25fr) minmax(145px,1.25fr) minmax(144px,1fr) minmax(135px,1fr);
  grid-template-rows:minmax(0,1fr) auto;
  padding:7px 10px;
  gap:5px 10px;
  border-top:1px solid #acbfce;
  background:#edf3f7;
  overflow:auto;
}
#graphicalBottom > :is(section,.graphic-palette-block) { min-width:0; padding-right:8px; border-right:1px solid #c2d0dc; overflow:auto; }
#graphicalBottom input { width:100%; margin:4px 0; }
#graphicalBottom button { margin:2px 0; }
#graphicalBottom strong,#graphicalBottom label { font-weight:700; color:#25485f; }
#graphicalBottom section span { color:#486173; font-size:11px; }
.dock-pattern-strip { display:flex; height:10px; margin-top:4px; border:1px solid #a1b3c2; overflow:hidden; }
.dock-pattern-strip i { flex-basis:0; }
#dockYarns { display:flex; flex-wrap:wrap; gap:3px; max-height:52px; overflow:auto; margin:4px 0; }
#dockYarns button { min-width:23px; max-width:68px; padding:2px 3px; overflow:hidden; text-overflow:ellipsis; }
.graphic-apply-block { grid-column:1/-1; }
#applyDockPattern { color:white; background:#245b78; border-color:#245b78; }
@media(max-width:850px) {
  #graphicalBottom { grid-template-columns: repeat(4,minmax(112px,1fr)); }
}

.left-clipboard { display:flex; flex-wrap:wrap; gap:3px; margin-top:6px; }
.left-clipboard button { padding:3px 5px; }
#fullWeaveCanvas:focus-visible { outline:2px solid #28739c; outline-offset:-2px; }
.dock-operation { display:inline-flex; align-items:center; gap:4px; margin-left:4px; }
.dock-operation select { max-width:100%; }
.graphic-apply-block { display:flex; align-items:center; flex-wrap:wrap; gap:5px; }

#graphicalBottom .dock-operation { white-space:nowrap; }
#graphicalBottom .dock-operation select { width:auto; margin:0; font-weight:400; }

#compoundWeaveDialog { min-width:min(420px,93vw); }
#compoundPreview { border:1px solid #a0b0bb; background:white; max-width:100%; image-rendering:pixelated; }
#weaveClipList { max-height:45vh; overflow:auto; }
#weaveClipList > div { display:flex; flex-wrap:wrap; align-items:center; gap:6px; padding:5px 0; }
#weaveClipList strong { flex:1; }

/* Compact graphical tools, with larger editing surfaces and named control groups. */

#graphicalLeft,#activeDesignTools { padding:7px 6px; }
#graphicalLeft h2,#activeDesignTools h2 { font-size:12px; margin:0 0 5px; }
#graphicalLeft h3,#activeDesignTools h3 { font-size:10px; margin:0 0 3px; }
.draw-mode-buttons,.dock-peg-buttons,.dock-button-pair,.dock-inline-pair {
  display:flex; flex-wrap:wrap; gap:3px; align-items:center;
}
.draw-mode-buttons button,.dock-peg-buttons button,.dock-button-pair button {
  min-width:0; flex:1 1 44%; white-space:nowrap;
}
#graphicalLeft button,#activeDesignTools button,#graphicalBottom button {
  border:1px solid #b3c4d0; border-radius:2px; background:#f8fbfd;
  min-height:23px; padding:2px 5px; font-size:11px;
}
#graphicalLeft button:hover,#activeDesignTools button:hover,#graphicalBottom button:hover {
  background:#e0edf6; border-color:#779eb5;
}
#graphicalLeft button[aria-pressed="true"],#graphicalBottom #applyDockPattern {
  background:#245b78; color:white; border-color:#245b78;
}
#graphicalLeft #nativeWeaveTools { display:flex; flex-direction:column; gap:4px; margin-top:5px; }
.weave-dock-group { padding-top:3px; border-top:1px solid #d0dce4; }
.weave-dock-icons { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:2px; }
#graphicalLeft #nativeWeaveTools button { width:100%; height:24px; min-height:24px; padding:1px; }
#graphicalLeft #nativeWeaveTools img { width:18px; height:18px; object-fit:contain; }
#graphicalLeft details summary { font-size:10px; cursor:pointer; padding:3px 0; color:#25485f; }
#graphicalLeft details .weave-dock-group { border:0; }
#graphicalLeft details h3 { display:none; }
#dockWeaveToolHint { display:block; min-height:15px; font-size:10px; color:#36546a; margin-top:3px; }
#graphicalLeft .left-clipboard { margin-top:4px; gap:3px; }
#graphicalLeft .left-clipboard button { flex:1 1 44%; white-space:nowrap; }
#graphicalLeft .dock-peg-section {
  display:grid; grid-template-columns:minmax(0,1fr) auto; align-items:center; gap:4px;
  margin-top:6px; padding-top:5px;
}
#graphicalLeft .dock-peg-buttons { grid-column:1/-1; }
#graphicalLeft .dock-peg-buttons button { width:auto; margin:0; padding-inline:2px; }
#pegMiniGrid canvas { width:30px; height:30px; }
#bookSwatches { gap:4px; }
#bookSwatches button { gap:3px; padding:4px 2px; white-space:nowrap; }
#bookSwatches canvas { width:34px; height:34px; }
#bookSelection { margin:4px 0; font-size:10px; }
#activeDesignTools > section { margin-top:5px; padding-top:5px; }
#activeDesignTools section button { margin:0; }
#graphicalBottom { padding:5px 8px; gap:4px 8px; }
#graphicalBottom > :is(section,.graphic-palette-block) { padding:0 6px 0 0; }
#graphicalBottom :is(button,select,input) { margin-top:2px; margin-bottom:2px; }
#graphicalBottom input { padding:3px 5px; }
#graphicalBottom .dock-operation select { max-width:144px; font-size:10px; padding:3px; }
#dockYarns { margin:2px 0; max-height:35px; }
#graphicalBottom #dockYarns button { min-height:18px; padding:1px 4px; margin:0; }
.graphic-apply-block { gap:4px 7px; }
@media(max-width:850px) {
  .show-graphical .studio-stage { --left-tools:103px; --right-tools: min(288px, 43vw); --bottom-tools:152px; }
  #graphicalBottom .dock-operation select { max-width:108px; }
}

#graphicalLeft .left-clipboard { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); }
#graphicalLeft .left-clipboard button { min-width:0; padding-inline:2px; }
#graphicalBottom .graphic-pattern-block > div:first-child {
  display:flex; align-items:baseline; justify-content:space-between; gap:4px;
}
#graphicalBottom .graphic-pattern-block > div:first-child label { display:inline; margin:0; }
#graphicalBottom .graphic-pattern-block > div:first-child span { white-space:nowrap; font-size:10px; }
#graphicalBottom .graphic-pattern-block .dock-operation { margin:0 0 0 2px; }
#graphicalBottom .dock-pattern-strip { margin-top:3px; }

.show-graphical #weaveWindow > .window-content { min-height:0; padding:4px; }
.show-graphical #weaveWindow .window-menubar { flex-wrap:wrap; }
.show-graphical #weaveWindow .window-menubar button { padding:3px 5px; }
.show-graphical #weaveWindow .weave-grid-options { flex-wrap:wrap; gap:3px; }
.show-graphical #weaveWindow .weave-grid-options :is(select,button) { padding:3px; }
.show-graphical #weaveScroll { min-height:44px; }
.show-graphical #bookSwatches { grid-template-columns:repeat(4,minmax(0,1fr)); }
#activeDesignTools .dock-right-group:last-child .dock-button-pair {
  display:grid; grid-template-columns:repeat(3,minmax(0,1fr));
}

/* Moving Graphical panels never changes the underlying edit controls. */
.graph-panel-bar,.graph-panel-grip { display:none; }
#graphicalWorkspaceSettings[hidden],.panel-dock-zones[hidden],.panel-dock-ghost[hidden] { display:none; }
#graphicalWorkspaceSettings { flex:0 0 auto; align-self:center; white-space:nowrap; }
.show-graphical .studio-stage > .workspace {
  margin-left:var(--occupied-left,var(--left-tools));
  margin-right:var(--occupied-right,var(--right-tools));
  height:calc(100% - var(--occupied-bottom,var(--bottom-tools)));
}
.show-graphical .studio-stage > [data-graph-panel] {
  position:absolute;
  inset:var(--panel-y) auto auto var(--panel-x) !important;
  width:var(--panel-w);
  height:var(--panel-h);
  max-width:none;
  max-height:none;
  box-sizing:border-box;
}
.show-graphical .studio-stage > #weaveWindow[data-graph-panel] { width:var(--panel-w); height:var(--panel-h); }
.show-graphical .studio-stage > [data-graph-dock="float"] {
  z-index:var(--panel-layer,24) !important;
  background:#edf3f7;
  border:1px solid #80a0b6;
  box-shadow:0 5px 14px #18354440;
}
.show-graphical .graph-panel-bar {
  position:absolute;
  inset:0 0 auto 0;
  height:23px;
  display:flex;
  align-items:center;
  gap:2px;
  padding:0 2px 0 5px;
  background:#dbe7ef;
  color:#203e52;
  border-bottom:1px solid #aec2d0;
  z-index:2;
}
.show-graphical .graph-panel-handle {
  flex:1; min-width:0; overflow:hidden; text-overflow:ellipsis; white-space:nowrap;
  cursor:grab; font-size:11px; font-weight:700; touch-action:none; user-select:none;
  line-height:21px;
}
.panel-layout-dragging .graph-panel-handle { cursor:grabbing; }
.show-graphical [data-graph-panel] > .graph-panel-bar button {
  min-width:17px; min-height:17px; height:17px; margin:0;
  padding:0 2px; border:1px solid transparent; background:transparent; line-height:14px;
}
.show-graphical [data-graph-panel] > .graph-panel-bar button:hover {
  background:#f5fafd; border-color:#a6bfce;
}
.show-graphical #weaveWindow > .window-title,
.show-graphical :is(#graphicalLeft,#activeDesignTools) > h2,
.show-graphical .graphic-palette-block > strong { display:none; }
.show-graphical :is(#graphicalLeft,#activeDesignTools,#graphicalBottom,#weaveWindow) { padding-top:26px; }
.show-graphical .graphic-palette-block { position:relative; padding-top:22px !important; }
.show-graphical .studio-stage > .graphic-palette-block { overflow:auto; padding:25px 6px 6px !important; background:#edf3f7; }
.show-graphical .graphic-palette-block[data-graph-dock="inline"] .graph-panel-bar { height:20px; }
.show-graphical .graph-panel-collapsed { overflow:hidden !important; }
.show-graphical .graph-panel-collapsed > :not(.graph-panel-bar) { display:none !important; }
.show-graphical .studio-stage > #graphicalBottom:not([data-graph-dock="bottom"]) {
  grid-template-columns:minmax(0,1fr); grid-template-rows:auto; align-content:start;
}
.show-graphical .studio-stage > #graphicalBottom:not([data-graph-dock="bottom"]) > * { overflow:visible; }
.show-graphical #graphicalBottom:not(.has-inline-yarns)[data-graph-dock="bottom"] {
  grid-template-columns:repeat(3,minmax(135px,1fr));
}
.show-graphical .studio-stage > :is(#activeDesignTools,#graphicalLeft)[data-graph-dock="bottom"] {
  overflow:auto;
}
.show-graphical .graph-panel-grip { position:absolute; z-index:3; touch-action:none; }
.show-graphical [data-graph-dock="left"] > .graph-panel-edge-grip {
  display:block; inset:24px 0 0 auto; width:6px; cursor:ew-resize;
}
.show-graphical [data-graph-dock="right"] > .graph-panel-edge-grip {
  display:block; inset:24px auto 0 0; width:6px; cursor:ew-resize;
}
.show-graphical [data-graph-dock="bottom"] > .graph-panel-edge-grip {
  display:block; inset:0 0 auto 0; height:4px; cursor:ns-resize;
}

.show-graphical :is([data-graph-dock="left"],[data-graph-dock="right"]) > .graph-panel-stack-grip {
  display:block; inset:0 0 auto 0; height:4px; cursor:ns-resize;
}
.show-graphical .graph-panel-grip:hover { background-color:#76a4be99; }
.panel-dock-zones,.panel-dock-ghost { position:absolute; z-index:150; pointer-events:none; }
.panel-dock-zones { inset:0; }
.panel-dock-zones span {
  position:absolute; display:grid; place-items:center; padding:6px;
  border:1px dashed #4784a7; background:#cee5f3d0; color:#173b54;
  font-size:11px; font-weight:700;
}
.panel-dock-zones [data-drop-zone="left"] { inset:38% auto 38% 5px; }
.panel-dock-zones [data-drop-zone="right"] { inset:38% 5px 38% auto; }
.panel-dock-zones [data-drop-zone="bottom"] { inset:auto 38% 5px 38%; }
.panel-dock-zones[data-active-zone="left"] [data-drop-zone="left"],
.panel-dock-zones[data-active-zone="right"] [data-drop-zone="right"],
.panel-dock-zones[data-active-zone="bottom"] [data-drop-zone="bottom"] {
  background:#245b78; color:white;
}
.panel-dock-ghost {
  min-width:148px; max-width:220px; padding:5px 7px; background:#245b78; color:white; border-radius:3px;
}
.panel-layout-announcement { position:absolute; width:1px; height:1px; overflow:hidden; clip-path:inset(50%); }
#graphicalWorkspaceDialog { max-width:min(420px,calc(100vw - 30px)); }
#graphicalWorkspaceDialog .row { margin-top:12px; flex-wrap:wrap; }

.show-graphical .studio-stage > [data-graph-panel] {
  width:var(--panel-w) !important;
  height:var(--panel-h) !important;
}
.show-graphical #weaveWindow[data-graph-dock="float"] { z-index:var(--panel-layer,24) !important; }

.show-graphical [data-graph-panel].graph-panel-collapsed { padding:0 !important; min-height:0; }
.show-graphical #graphicalLeft > .graph-panel-bar { gap:1px; padding-inline:3px 1px; }
.show-graphical #graphicalLeft > .graph-panel-bar button { min-width:15px; padding:0 1px; }

#graphicalWorkspaceDialog { width:min(526px,calc(100vw - 28px)); padding:14px; }
.workspace-dialog-heading { display:flex; align-items:center; justify-content:space-between; gap:8px; }
.workspace-dialog-heading h2 { margin:0; font-size:16px; }
.workspace-layout-manager {
  display:grid; grid-template-columns:minmax(155px,.9fr) minmax(190px,1.1fr); gap:12px; margin-top:12px;
}
#workspacePanels { display:grid; gap:3px; align-content:start; }
#workspacePanels button {
  display:grid; grid-template-columns:minmax(0,1fr); text-align:left; padding:5px 7px;
  background:#f5f9fc; border:1px solid #bfd0dc; border-radius:3px;
}
#workspacePanels button small { color:#506c7f; }
#workspacePanels button[aria-pressed="true"] { border-color:#3e799d; background:#dceaf3; }
.workspace-layout-manager section {
  background:#edf4f8; border:1px solid #c1d0db; border-radius:3px; padding:9px;
}
#workspaceSelectedPanel { margin:0 0 8px; font-size:13px; }
#workspaceDockActions { display:grid; grid-template-columns:1fr 1fr; gap:5px; }
#workspaceDockActions button[hidden] { display:none; }
#workspaceDockActions button[aria-pressed="true"] { background:#245b78; color:white; border-color:#245b78; }
#workspaceDockActions button:last-child { grid-column:1/-1; }
.workspace-panel-options,.workspace-history { display:flex; flex-wrap:wrap; gap:5px; margin-top:9px; }
.workspace-action-hint { margin:10px 0 0; color:#3f5d71; font-size:11px; }
.workspace-history { padding-top:8px; border-top:1px solid #b8cbd8; }
.panel-drop-preview {
  position:absolute; top:var(--panel-y); left:var(--panel-x); width:var(--panel-w); height:var(--panel-h);
  z-index:140; pointer-events:none; background:#70b2d53d; border:2px solid #277eab;
}
.panel-drop-preview[hidden] { display:none; }
@media(max-width:460px) {
  .workspace-layout-manager { grid-template-columns:1fr; }
  #workspacePanels { grid-template-columns:repeat(2,minmax(0,1fr)); }
}

#colourEditorGrid button[aria-pressed="true"] { outline: 2px solid #122d40; outline-offset: 2px; }
#colourEditorGrid button:disabled { opacity: .7; }
#coloursWindow .colour-controls { display: flex; flex-wrap: wrap; align-items: end; gap: 6px 8px; }
#coloursWindow .colour-controls label { margin: 0; }
#coloursWindow .colour-picker-label input { width: 52px; cursor: pointer; }
#viewport.picking-colour, #viewport.picking-colour canvas { cursor: crosshair; }
#pickFabricColour[aria-pressed="true"] { background: #245b78; color: #fff; }
#pantoneTarget { font-weight: 600; }

.picker-pantone { margin-top: 7px; }
.picker-pantone > label { margin: 0 0 3px; }
.picker-pantone-line { display: flex; gap: 3px; }
.picker-pantone-line input { flex: 1; min-width: 0; }
#pickerPantoneList { margin-top: 3px; max-height: 170px; overflow: auto; overscroll-behavior: contain; background: white; border: 1px solid #899cad; }
#pickerPantoneList [role="option"] { display: flex; align-items: center; gap: 7px; padding: 4px 6px; cursor: pointer; white-space: nowrap; }
#pickerPantoneList [role="option"]:hover, #pickerPantoneList [aria-selected="true"] { background: #e1edf5; }
.picker-pantone-swatch { width: 18px; height: 15px; flex: none; border: 1px solid #899cad; }
#pickerPantoneStatus:empty { display: none; }

#coloursWindow .colour-values {
  display: grid;
  grid-template-columns: minmax(65px, .32fr) minmax(0, 1fr);
  align-items: start;
  gap: 8px;
  margin-top: 7px;
}
#coloursWindow .colour-values > label { margin: 0; }
#coloursWindow .colour-values .picker-pantone { margin: 0; }
#coloursWindow .colour-values .picker-pantone > label { margin-bottom: 4px; }

.edit-scope { display: inline-flex; gap: 2px; align-items: center; margin-bottom: 4px; }
.edit-scope button[data-edit-scope] { padding: 3px 7px; min-width: 39px; line-height: 1; }
.edit-scope button[aria-pressed="true"] { background: #205874; color: white; border-color: #205874; }
.native-workspace #threadWindow { width: min(590px, 94vw); }
#threadWindow > .window-content { overflow: auto; }
#threadWindow .window-content { padding: 5px; }
.thread-file-tools { margin: 0 0 4px; }
.ta-axes { grid-template-columns: repeat(2,minmax(0,1fr)); gap: 5px; }
#threadAuthoring .ta-axis { padding: 4px; }
.ta-axis > strong { font-size: 12px; }
.ta-axis-setup { margin: 3px 0; gap: 4px; }
#threadAuthoring table { width: 100%; border-collapse: collapse; }
#threadAuthoring th, #threadAuthoring td { padding: 1px 2px; text-align: left; }
#threadAuthoring input[type=number] { width: 55px; }
#threadAuthoring select { max-width: 105px; }
#threadAuthoring .ta-rowtools { white-space: nowrap; }
#threadAuthoring button { margin: 1px; padding-block: 3px; }
#threadAuthoring .ta-rowtools button { min-width: 19px; padding-inline: 3px; }
#threadAuthoring .ta-swatch { display:inline-block; width: 18px; height: 18px; padding:0; min-width: 0; vertical-align:middle; margin-right:4px; }
#threadAuthoring .ta-swatch:hover, #threadAuthoring .ta-swatch:focus-visible { outline: 1px solid #112f40; }
#threadAuthoring p[id$="-summary"] { margin: 3px 0; }
#threadAuthoring .ta-options { margin-top: 3px; padding-top: 2px; }
#threadAuthoring .ta-options summary { padding-block: 2px; }
.dock-pattern-strip button { flex-basis: 0; min-width: 1px; height: 100%; padding: 0; border: 0; border-radius: 0; }
.dock-pattern-strip button:hover, .dock-pattern-strip button:focus-visible { outline: 1px solid white; outline-offset: -2px; }
.dock-pattern-strip { height: 14px; }
#coloursWindow .colour-controls { gap: 4px 6px; }
#coloursWindow .colour-values { margin-top: 4px; }
.native-workspace .tool-window .window-menubar { gap: 2px; padding-block: 2px; }
.native-workspace .tool-window .window-menubar button { padding-block: 3px; }

@media (max-width: 560px) {
  .ta-axes { grid-template-columns: 1fr; }
}

#graphicsPrintPanel{position:fixed;z-index:40;right:10px;top:100px;width:min(308px,calc(100vw - 20px));max-height:calc(100vh - 128px);overflow:auto;border:1px solid #aabccb;border-radius:5px;background:#f6f8f8;color:#263b49;box-shadow:0 6px 22px #203b4e34;font:13px/1.35 system-ui,sans-serif}
#graphicsPrintPanel[hidden],#graphicsPrintPanel [hidden]{display:none}
#graphicsPrintPanel header{position:sticky;top:0;z-index:1;display:flex;align-items:center;justify-content:space-between;padding:8px 12px;background:#24475c;color:white}
#graphicsPrintPanel header button{background:transparent;color:white;border:0;font-size:19px}
#graphicsPrintPanel section{padding:10px 12px}
#graphicsPrintPanel input:not([type=checkbox]),#graphicsPrintPanel select{min-width:0;width:100%;padding:4px;border:1px solid #b4c5ce;border-radius:3px;background:white}
#graphicsPrintPanel label{display:flex;flex-direction:column;gap:3px}
#graphicsPrintPanel .gp-actions,#graphicsPrintPanel .gp-size-header{display:flex;align-items:center;gap:8px;justify-content:space-between;margin-bottom:8px}
#graphicsPrintPanel .gp-actions>label:last-child{max-width:99px}
#graphicsPrintPanel .gp-upload{position:relative;cursor:pointer;padding:6px 10px;border-radius:4px;background:#28566d;color:white}
#graphicsPrintPanel .gp-upload input{position:absolute;inset:0;opacity:0;cursor:pointer}
#gpLibrary{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:6px;max-height:171px;overflow:auto;margin:6px 0 12px}
#gpLibrary button{min-width:0;padding:3px;border:1px solid #c8d3d8;background:white;border-radius:4px}
#gpLibrary button[aria-pressed=true]{border-color:#28617e;background:#dcecf4}
#gpLibrary canvas{display:block;width:100%;height:39px;object-fit:contain;background:#f0f2f2}
#gpLibrary span{display:block;font-size:10px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;text-align:left}
#graphicsPrintPanel .gp-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:6px;margin:6px 0}
#graphicsPrintPanel .gp-size-header select{width:auto}
#graphicsPrintPanel .gp-size-header label{display:inline-flex;flex-direction:row;align-items:center;white-space:nowrap}
#graphicsPrintPanel details,#graphicsPrintPanel #gpStatus{margin:8px 0;color:#475c69}

.adjustable-tool .tool-move-handle{cursor:move;touch-action:none;user-select:none}
.tool-size-handle{position:absolute;display:block;z-index:5;touch-action:none;user-select:none}
.tool-size-handle[data-tool-resize=n]{top:0;left:13px;right:13px;height:7px;cursor:ns-resize}
.tool-size-handle[data-tool-resize=s]{bottom:0;left:13px;right:13px;height:7px;cursor:ns-resize}
.tool-size-handle[data-tool-resize=e]{right:0;top:13px;bottom:13px;width:7px;cursor:ew-resize}
.tool-size-handle[data-tool-resize=w]{left:0;top:13px;bottom:13px;width:7px;cursor:ew-resize}
.tool-size-handle:is([data-tool-resize=ne],[data-tool-resize=nw],[data-tool-resize=se],[data-tool-resize=sw]){width:13px;height:13px}
.tool-size-handle[data-tool-resize=ne]{top:0;right:0;cursor:nesw-resize}
.tool-size-handle[data-tool-resize=nw]{top:0;left:0;cursor:nwse-resize}
.tool-size-handle[data-tool-resize=se]{bottom:0;right:0;cursor:nwse-resize}
.tool-size-handle[data-tool-resize=sw]{bottom:0;left:0;cursor:nesw-resize}
.graph-float-resize{display:none}
.show-graphical [data-graph-dock="float"]:not(.graph-panel-collapsed) > .graph-float-resize{display:block}
.adjustable-tool.tool-adjusting{user-select:none}
.adjustable-tool.tool-adjusting iframe{pointer-events:none}
.adjustable-tool.minimized .tool-size-handle,.show-graphical #weaveWindow[data-graph-panel] .tool-size-handle:not(.graph-float-resize){display:none}
