:root {
  --szpw-accent: #ff6300;
  --szpw-accent-2: #ff8a3d;
  --szpw-bg: #0b0f0e;
  --szpw-panel: #111715;
  --szpw-panel-2: #151c19;
  --szpw-panel-3: #1b2420;
  --szpw-line: rgba(177, 201, 191, .18);
  --szpw-line-strong: rgba(177, 201, 191, .34);
  --szpw-text: #f6fbf8;
  --szpw-muted: #96a79f;
  --szpw-good: #3ddc97;
  --szpw-warn: #ffb454;
  --szpw-danger: #ff5f6d;
  --szpw-shadow: 0 -22px 60px rgba(0, 0, 0, .52);
  --szpw-radius: 14px;
  --szpw-drawer-collapsed: 44px;
}

html[data-theme="light"], html.light-layout {
  --szpw-bg: #f1f5f3;
  --szpw-panel: #ffffff;
  --szpw-panel-2: #f8faf9;
  --szpw-panel-3: #edf2ef;
  --szpw-line: rgba(26, 47, 38, .14);
  --szpw-line-strong: rgba(26, 47, 38, .28);
  --szpw-text: #17231d;
  --szpw-muted: #64766d;
  --szpw-shadow: 0 -22px 60px rgba(19, 35, 28, .18);
}

#szpw-root,
#szpw-root *,
.szpw-modal-layer,
.szpw-modal-layer * {
  box-sizing: border-box;
}

#szpw-root {
  position: fixed;
  inset: auto 0 0;
  z-index: 2147482600;
  color: var(--szpw-text);
  font: 500 13px/1.45 Manrope, Montserrat, Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  pointer-events: none;
}

#szpw-root.is-closed,
#szpw-root.is-suspended-by-child,
.szpw-toast-stack.is-suspended-by-child,
html.szpw-drawer-suspended .szpw-editor-capture-fallback {
  display: none !important;
}

.szpw-shell {
  pointer-events: auto;
  width: min(1500px, calc(100vw - 24px));
  height: min(74vh, 780px);
  margin: 0 auto;
  overflow: hidden;
  border: 1px solid var(--szpw-line-strong);
  border-bottom: 0;
  border-radius: 18px 18px 0 0;
  background: linear-gradient(145deg, rgba(255, 99, 0, .055), transparent 28%), var(--szpw-bg);
  box-shadow: var(--szpw-shadow);
  transform: translateY(0);
  transition: height .24s ease, transform .24s ease, box-shadow .24s ease;
}

.szpw-shell.is-minimized {
  height: var(--szpw-drawer-collapsed);
  box-shadow: 0 -8px 28px rgba(0, 0, 0, .34);
}

.szpw-minibar {
  height: var(--szpw-drawer-collapsed);
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  padding: 0 14px;
  border-bottom: 1px solid var(--szpw-line);
  background: rgba(15, 21, 18, .96);
  backdrop-filter: blur(18px);
  cursor: pointer;
  user-select: none;
}

html[data-theme="light"] .szpw-minibar,
html.light-layout .szpw-minibar { background: rgba(255,255,255,.96); }

.szpw-minibar-main {
  min-width: 0;
  min-height: 100%;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  padding: 0;
  border: 0;
  outline: none;
  color: inherit;
  background: transparent;
  font: inherit;
  text-align: left;
  cursor: pointer;
}
.szpw-minibar-main:focus-visible {
  border-radius: 10px;
  box-shadow: 0 0 0 3px rgba(255, 99, 0, .3);
}

.szpw-minibar-controls {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 6px;
}

.szpw-window-actions {
  display: none;
  align-items: center;
  gap: 6px;
}

.szpw-window-button {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  padding: 0;
  border: 1px solid var(--szpw-line);
  border-radius: 10px;
  color: var(--szpw-text);
  background: var(--szpw-panel-2);
  cursor: pointer;
}

.szpw-window-button:hover {
  border-color: var(--szpw-line-strong);
  background: var(--szpw-panel-3);
}

.szpw-window-button:focus-visible {
  outline: 2px solid var(--szpw-accent-2);
  outline-offset: 2px;
}

.szpw-window-button svg {
  width: 17px;
  height: 17px;
}

.szpw-window-close:hover,
.szpw-window-close:focus-visible {
  border-color: rgba(255, 95, 109, .48);
  color: #fff;
  background: rgba(255, 95, 109, .2);
}

.szpw-grip {
  width: 34px;
  height: 4px;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--szpw-accent), var(--szpw-accent-2));
}

.szpw-minibar-title {
  display: flex;
  align-items: center;
  gap: 9px;
  min-width: 0;
}

.szpw-minibar-title strong { font-size: 13px; white-space: nowrap; }
.szpw-minibar-title span { color: var(--szpw-muted); font-size: 11px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.szpw-counts { display: flex; gap: 6px; }
.szpw-count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 26px;
  height: 24px;
  padding: 0 8px;
  border: 1px solid var(--szpw-line);
  border-radius: 999px;
  color: var(--szpw-muted);
  background: var(--szpw-panel-2);
  font-size: 10px;
}

.szpw-chevron {
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  border: 0;
  border-radius: 8px;
  color: var(--szpw-text);
  background: transparent;
  cursor: pointer;
}
.szpw-chevron:hover { background: var(--szpw-panel-3); }
.szpw-chevron svg { width: 16px; height: 16px; transition: transform .24s ease; }
.szpw-shell:not(.is-minimized) .szpw-chevron svg { transform: rotate(180deg); }

.szpw-body {
  height: calc(100% - var(--szpw-drawer-collapsed));
  display: grid;
  grid-template-columns: 198px minmax(0, 1fr);
  min-height: 0;
}
.szpw-shell.is-minimized .szpw-body { display: none; }

.szpw-nav {
  min-height: 0;
  padding: 14px 10px;
  border-right: 1px solid var(--szpw-line);
  background: var(--szpw-panel);
  overflow: auto;
}

.szpw-brand {
  padding: 6px 8px 14px;
  border-bottom: 1px solid var(--szpw-line);
  margin-bottom: 10px;
}
.szpw-brand strong { display: block; font-size: 16px; letter-spacing: -.02em; }
.szpw-brand span { display: block; margin-top: 3px; color: var(--szpw-muted); font-size: 10px; line-height: 1.4; }

.szpw-tab {
  width: 100%;
  min-height: 42px;
  display: grid;
  grid-template-columns: 30px minmax(0, 1fr) auto;
  align-items: center;
  gap: 8px;
  margin: 3px 0;
  padding: 6px 8px;
  border: 1px solid transparent;
  border-radius: 10px;
  color: var(--szpw-muted);
  background: transparent;
  text-align: left;
  cursor: pointer;
}
.szpw-tab:hover { color: var(--szpw-text); background: var(--szpw-panel-2); }
.szpw-tab.is-active {
  color: var(--szpw-text);
  border-color: rgba(255, 99, 0, .34);
  background: rgba(255, 99, 0, .11);
}
.szpw-tab-icon {
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: var(--szpw-panel-3);
  color: currentColor;
}
.szpw-tab.is-active .szpw-tab-icon { background: var(--szpw-accent); color: #fff; }
.szpw-tab-icon svg { width: 16px; height: 16px; }
.szpw-tab b { font-size: 12px; font-weight: 750; }
.szpw-tab small { color: inherit; opacity: .7; font-size: 9px; }

.szpw-account-state {
  margin-top: 14px;
  padding: 10px;
  border: 1px solid var(--szpw-line);
  border-radius: 10px;
  background: var(--szpw-panel-2);
}
.szpw-account-state b { display: block; font-size: 10px; text-transform: uppercase; letter-spacing: .08em; }
.szpw-account-state span { display: block; margin-top: 4px; color: var(--szpw-muted); font-size: 9px; line-height: 1.45; }
.szpw-account-state.is-synced b { color: var(--szpw-good); }

.szpw-main { min-width: 0; min-height: 0; display: flex; flex-direction: column; background: var(--szpw-bg); }
.szpw-toolbar {
  min-height: 58px;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  border-bottom: 1px solid var(--szpw-line);
  background: var(--szpw-panel);
}
.szpw-toolbar-copy { min-width: 0; flex: 1; }
.szpw-toolbar-copy h2 { margin: 0; font-size: 16px; letter-spacing: -.02em; }
.szpw-toolbar-copy p { margin: 2px 0 0; color: var(--szpw-muted); font-size: 10px; }
.szpw-toolbar-actions { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; justify-content: flex-end; }

.szpw-content { flex: 1; min-height: 0; overflow: auto; padding: 14px; }
.szpw-grid { display: grid; gap: 12px; }
.szpw-grid.two { grid-template-columns: minmax(190px, 260px) minmax(0, 1fr); }
.szpw-grid.cards { grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); }
.szpw-stack { display: grid; gap: 10px; }

.szpw-panel {
  border: 1px solid var(--szpw-line);
  border-radius: var(--szpw-radius);
  background: var(--szpw-panel);
  overflow: hidden;
}
.szpw-panel-head {
  min-height: 46px;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 9px 11px;
  border-bottom: 1px solid var(--szpw-line);
}
.szpw-panel-head h3 { margin: 0; font-size: 12px; flex: 1; }
.szpw-panel-body { padding: 11px; }

.szpw-button,
.szpw-icon-button {
  appearance: none;
  border: 1px solid var(--szpw-line-strong);
  border-radius: 9px;
  color: var(--szpw-text);
  background: var(--szpw-panel-2);
  font: inherit;
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
  transition: transform .12s ease, border-color .12s ease, background .12s ease, opacity .12s ease;
}
.szpw-button { min-height: 34px; padding: 7px 11px; }
.szpw-icon-button { width: 32px; height: 32px; display: inline-grid; place-items: center; padding: 0; }
.szpw-icon-button svg { width: 15px; height: 15px; }
.szpw-button:hover, .szpw-icon-button:hover { border-color: rgba(255,99,0,.55); transform: translateY(-1px); }
.szpw-button:disabled, .szpw-icon-button:disabled { opacity: .45; cursor: not-allowed; transform: none; }
.szpw-button.primary { border-color: var(--szpw-accent); background: var(--szpw-accent); color: #fff; }
.szpw-button.ghost { background: transparent; }
.szpw-button.danger, .szpw-icon-button.danger { color: var(--szpw-danger); }
.szpw-button.good { color: #07150f; border-color: var(--szpw-good); background: var(--szpw-good); }
.szpw-button.compact { min-height: 28px; padding: 5px 8px; font-size: 10px; }

.szpw-field { display: grid; gap: 5px; min-width: 0; }
.szpw-field > span,
.szpw-field > label { color: var(--szpw-muted); font-size: 9px; font-weight: 750; letter-spacing: .06em; text-transform: uppercase; }
.szpw-field input,
.szpw-field select,
.szpw-field textarea,
.szpw-input {
  width: 100%;
  min-width: 0;
  min-height: 36px;
  padding: 7px 9px;
  border: 1px solid var(--szpw-line-strong);
  border-radius: 9px;
  outline: none;
  color: var(--szpw-text);
  background: var(--szpw-panel-2);
  font: inherit;
  font-size: 11px;
}
.szpw-field textarea { min-height: 78px; resize: vertical; }
.szpw-field input:focus,
.szpw-field select:focus,
.szpw-field textarea:focus,
.szpw-input:focus { border-color: var(--szpw-accent); box-shadow: 0 0 0 2px rgba(255,99,0,.14); }
.szpw-form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.szpw-form-grid.three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.szpw-form-grid .span-all { grid-column: 1 / -1; }

.szpw-check {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: var(--szpw-muted);
  font-size: 10px;
  cursor: pointer;
}
.szpw-check input { accent-color: var(--szpw-accent); }

.szpw-collection-list { display: grid; gap: 4px; }
.szpw-collection-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 4px;
  padding: 4px;
  border: 1px solid transparent;
  border-radius: 9px;
}
.szpw-collection-row.is-active { border-color: rgba(255,99,0,.36); background: rgba(255,99,0,.09); }
.szpw-collection-select {
  min-width: 0;
  padding: 7px 8px;
  border: 0;
  border-radius: 7px;
  color: inherit;
  background: transparent;
  text-align: left;
  font: inherit;
  font-size: 11px;
  cursor: pointer;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.szpw-collection-select b { display: block; overflow: hidden; text-overflow: ellipsis; }
.szpw-collection-select small { display: block; color: var(--szpw-muted); font-size: 9px; }

.szpw-result-card {
  min-width: 0;
  border: 1px solid var(--szpw-line);
  border-radius: 12px;
  background: var(--szpw-panel);
  overflow: hidden;
}
.szpw-result-preview {
  height: 150px;
  display: grid;
  place-items: center;
  overflow: hidden;
  padding: 10px;
  background:
    linear-gradient(45deg, rgba(255,255,255,.035) 25%, transparent 25%, transparent 75%, rgba(255,255,255,.035) 75%),
    linear-gradient(45deg, rgba(255,255,255,.035) 25%, transparent 25%, transparent 75%, rgba(255,255,255,.035) 75%),
    var(--szpw-panel-2);
  background-size: 18px 18px;
  background-position: 0 0, 9px 9px;
}
.szpw-result-preview svg { width: 100%; height: 100%; max-width: 100%; max-height: 100%; display: block; }
.szpw-result-body { display: grid; gap: 9px; padding: 10px; }
.szpw-result-name { display: grid; grid-template-columns: minmax(0,1fr) auto; gap: 6px; align-items: center; }
.szpw-result-name input { font-weight: 750; }
.szpw-result-meta { display: flex; flex-wrap: wrap; gap: 6px; color: var(--szpw-muted); font-size: 9px; }
.szpw-result-meta span { padding: 3px 6px; border: 1px solid var(--szpw-line); border-radius: 999px; }
.szpw-size-row { display: grid; grid-template-columns: minmax(0,1fr) auto minmax(0,1fr); gap: 6px; align-items: end; }
.szpw-lock-button.is-active { color: #fff; border-color: var(--szpw-accent); background: var(--szpw-accent); }
.szpw-result-actions { display: flex; align-items: center; gap: 6px; }
.szpw-result-actions select { flex: 1; min-width: 0; }

.szpw-empty {
  min-height: 220px;
  display: grid;
  place-items: center;
  padding: 26px;
  border: 1px dashed var(--szpw-line-strong);
  border-radius: var(--szpw-radius);
  color: var(--szpw-muted);
  text-align: center;
  background: var(--szpw-panel);
}
.szpw-empty strong { display: block; margin-bottom: 6px; color: var(--szpw-text); font-size: 14px; }
.szpw-empty p { max-width: 430px; margin: 0; font-size: 10px; }

.szpw-material-card,
.szpw-job-card,
.szpw-machine-card,
.szpw-worker-card {
  border: 1px solid var(--szpw-line);
  border-radius: 12px;
  background: var(--szpw-panel);
  overflow: hidden;
}
.szpw-card-head { display: flex; align-items: flex-start; gap: 8px; padding: 10px; border-bottom: 1px solid var(--szpw-line); }
.szpw-card-head-copy { min-width: 0; flex: 1; }
.szpw-card-head h3 { margin: 0; font-size: 13px; }
.szpw-card-head p { margin: 3px 0 0; color: var(--szpw-muted); font-size: 9px; }
.szpw-card-body { padding: 10px; }
.szpw-card-actions { display: flex; gap: 5px; }
.szpw-swatch { width: 26px; height: 26px; flex: 0 0 auto; border: 2px solid rgba(255,255,255,.5); border-radius: 8px; box-shadow: 0 0 0 1px var(--szpw-line-strong); }
.szpw-tag-list { display: flex; flex-wrap: wrap; gap: 5px; }
.szpw-tag { padding: 4px 7px; border: 1px solid var(--szpw-line); border-radius: 7px; color: var(--szpw-muted); background: var(--szpw-panel-2); font-size: 9px; }

.szpw-sheet-row { display: grid; grid-template-columns: minmax(0,1fr) minmax(0,1fr) auto; gap: 7px; align-items: end; }
.szpw-sheet-list { display: grid; gap: 7px; }

.szpw-job-items { display: grid; gap: 6px; max-height: 260px; overflow: auto; padding: 2px; }
.szpw-job-item {
  display: grid;
  grid-template-columns: auto minmax(0,1fr) 72px;
  align-items: center;
  gap: 8px;
  padding: 7px;
  border: 1px solid var(--szpw-line);
  border-radius: 9px;
  background: var(--szpw-panel-2);
}
.szpw-job-item b { display: block; font-size: 10px; }
.szpw-job-item small { display: block; color: var(--szpw-muted); font-size: 8px; }

.szpw-nesting-preview { display: grid; gap: 10px; }
.szpw-nesting-sheet { border: 1px solid var(--szpw-line); border-radius: 10px; background: var(--szpw-panel-2); padding: 8px; }
.szpw-nesting-sheet h4 { margin: 0 0 6px; font-size: 10px; }
.szpw-nesting-sheet svg { width: 100%; max-height: 320px; display: block; border-radius: 6px; background: rgba(255,255,255,.02); }
.szpw-nesting-sheet rect.sheet { fill: rgba(255,255,255,.02); stroke: var(--szpw-line-strong); }
.szpw-nesting-sheet rect.part { fill: rgba(255,99,0,.18); stroke: var(--szpw-accent); }
.szpw-nesting-sheet text { fill: var(--szpw-text); font: 7px/1 sans-serif; pointer-events: none; }

.szpw-queue { display: grid; gap: 6px; }
.szpw-queue-row {
  display: grid;
  grid-template-columns: 24px minmax(0,1fr) 92px 108px auto;
  gap: 6px;
  align-items: center;
  padding: 7px;
  border: 1px solid var(--szpw-line);
  border-radius: 9px;
  background: var(--szpw-panel-2);
}
.szpw-queue-order { color: var(--szpw-muted); text-align: center; font-size: 9px; }
.szpw-queue-copy { min-width: 0; }
.szpw-queue-copy b { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 10px; }
.szpw-queue-copy small { display: block; color: var(--szpw-muted); font-size: 8px; }
.szpw-queue select { min-height: 30px; padding: 4px 6px; }
.szpw-queue-actions { display: flex; gap: 3px; }

.szpw-status {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 7px;
  border-radius: 999px;
  border: 1px solid var(--szpw-line);
  color: var(--szpw-muted);
  background: var(--szpw-panel-2);
  font-size: 9px;
}
.szpw-status::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.szpw-status.done { color: var(--szpw-good); }
.szpw-status.in_progress, .szpw-status.ready { color: var(--szpw-accent-2); }
.szpw-status.blocked { color: var(--szpw-danger); }

.szpw-worker-link {
  display: grid;
  grid-template-columns: minmax(0,1fr) auto;
  gap: 6px;
  margin-top: 8px;
}
.szpw-worker-link input { font-family: "IBM Plex Mono", ui-monospace, monospace; font-size: 9px; }

.szpw-modal-layer {
  position: fixed;
  inset: 0;
  z-index: 2147483000;
  display: grid;
  align-items: end;
  justify-items: center;
  padding: 18px 12px 0;
  color: var(--szpw-text);
  background: rgba(0, 0, 0, .58);
  backdrop-filter: blur(7px);
  font: 500 13px/1.45 Manrope, Montserrat, Inter, system-ui, sans-serif;
}
.szpw-modal {
  width: min(760px, 100%);
  max-height: min(86vh, 850px);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid var(--szpw-line-strong);
  border-bottom: 0;
  border-radius: 18px 18px 0 0;
  background: var(--szpw-bg);
  box-shadow: var(--szpw-shadow);
  animation: szpw-slide-up .22s ease both;
}
.szpw-modal.wide { width: min(1080px, 100%); }
@keyframes szpw-slide-up { from { transform: translateY(35px); opacity: .2; } to { transform: translateY(0); opacity: 1; } }
.szpw-modal-head { display: flex; align-items: center; gap: 10px; padding: 13px 14px; border-bottom: 1px solid var(--szpw-line); background: var(--szpw-panel); }
.szpw-modal-head-copy { min-width: 0; flex: 1; }
.szpw-modal-head h2 { margin: 0; font-size: 16px; }
.szpw-modal-head p { margin: 2px 0 0; color: var(--szpw-muted); font-size: 9px; }
.szpw-modal-body { min-height: 0; padding: 14px; overflow: auto; }
.szpw-modal-foot { display: flex; justify-content: flex-end; gap: 8px; padding: 10px 14px; border-top: 1px solid var(--szpw-line); background: var(--szpw-panel); }

.szpw-toast-stack { position: fixed; right: 16px; bottom: calc(var(--szpw-drawer-collapsed) + 16px); z-index: 2147483200; display: grid; gap: 8px; pointer-events: none; }
.szpw-toast {
  width: min(360px, calc(100vw - 32px));
  padding: 10px 12px;
  border: 1px solid var(--szpw-line-strong);
  border-radius: 11px;
  color: var(--szpw-text);
  background: var(--szpw-panel);
  box-shadow: 0 14px 36px rgba(0,0,0,.38);
  animation: szpw-toast-in .18s ease both;
  pointer-events: auto;
}
.szpw-toast b { display: block; font-size: 11px; }
.szpw-toast span { display: block; margin-top: 2px; color: var(--szpw-muted); font-size: 9px; }
.szpw-toast.error { border-color: rgba(255,95,109,.55); }
.szpw-toast.success { border-color: rgba(61,220,151,.55); }
@keyframes szpw-toast-in { from { transform: translateY(8px); opacity: 0; } }

.szpw-capture-button {
  width: 100%;
  min-height: 39px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin: 0 0 8px;
  border: 1px solid rgba(255,99,0,.55);
  border-radius: 9px;
  color: #fff;
  background: linear-gradient(135deg, #ff6300, #dc4a00);
  box-shadow: 0 9px 22px rgba(255,99,0,.18);
  font: 750 12px/1.2 Manrope, Montserrat, system-ui, sans-serif;
  cursor: pointer;
}
.szpw-capture-button:hover { filter: brightness(1.08); }
.szpw-capture-button svg { width: 16px; height: 16px; }
.szpw-inline-spinner {
  width: 17px;
  height: 17px;
  flex: 0 0 17px;
  display: inline-block;
  border: 2px solid rgba(255,255,255,.32);
  border-top-color: currentColor;
  border-radius: 50%;
  animation: szpw-share-spin .72s linear infinite;
}
.szpw-button.is-loading,
.szpw-capture-button.is-loading { cursor: progress; }

.szpw-editor-capture-fallback {
  position: fixed;
  right: 16px;
  bottom: calc(var(--szpw-drawer-collapsed) + 14px);
  z-index: 2147482500;
  width: auto;
  min-height: 36px;
  padding: 8px 12px;
  margin: 0;
  border-radius: 999px;
}
.szpw-shell:not(.is-minimized) ~ .szpw-editor-capture-fallback { display: none; }

.szpw-note {
  padding: 9px 10px;
  border: 1px solid var(--szpw-line);
  border-radius: 9px;
  color: var(--szpw-muted);
  background: var(--szpw-panel-2);
  font-size: 9px;
  line-height: 1.5;
}
.szpw-note.warning { border-color: rgba(255,180,84,.38); color: var(--szpw-warn); }
.szpw-note.good { border-color: rgba(61,220,151,.38); color: var(--szpw-good); }

.szpw-inline-actions { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.szpw-divider { height: 1px; margin: 10px 0; background: var(--szpw-line); }
.szpw-kpi-grid { display: grid; grid-template-columns: repeat(4, minmax(0,1fr)); gap: 8px; }
.szpw-kpi { padding: 9px; border: 1px solid var(--szpw-line); border-radius: 9px; background: var(--szpw-panel-2); }
.szpw-kpi b { display: block; font-size: 14px; }
.szpw-kpi span { display: block; margin-top: 2px; color: var(--szpw-muted); font-size: 8px; text-transform: uppercase; letter-spacing: .06em; }

/* Worker portal */
body.szpw-worker-page {
  min-height: 100vh;
  margin: 0;
  color: var(--szpw-text);
  background:
    radial-gradient(circle at 20% 0, rgba(255,99,0,.12), transparent 36%),
    var(--szpw-bg);
  font: 500 14px/1.45 Manrope, Montserrat, Inter, system-ui, sans-serif;
}
.szpw-worker-shell { width: min(1040px, calc(100% - 24px)); margin: 0 auto; padding: 24px 0 60px; }
.szpw-worker-header { display: flex; align-items: center; gap: 12px; margin-bottom: 16px; }
.szpw-worker-mark { width: 40px; height: 40px; display: grid; place-items: center; border-radius: 12px; color: #fff; background: var(--szpw-accent); font-weight: 900; }
.szpw-worker-header-copy { flex: 1; }
.szpw-worker-header h1 { margin: 0; font-size: 20px; }
.szpw-worker-header p { margin: 2px 0 0; color: var(--szpw-muted); font-size: 10px; }
.szpw-worker-login { width: min(430px, 100%); margin: 12vh auto 0; }
.szpw-worker-machine-grid { display: grid; gap: 12px; }
.szpw-worker-machine .szpw-queue-row { grid-template-columns: 24px minmax(0,1fr) 92px 112px auto; }

@media (max-width: 900px) {
  .szpw-shell { width: 100%; border-left: 0; border-right: 0; border-radius: 14px 14px 0 0; height: min(82vh, 820px); }
  .szpw-body { grid-template-columns: 74px minmax(0,1fr); }
  .szpw-brand { display: none; }
  .szpw-tab { grid-template-columns: 34px; justify-content: center; padding: 5px; }
  .szpw-tab b, .szpw-tab small { display: none; }
  .szpw-account-state { display: none; }
  .szpw-grid.two { grid-template-columns: 1fr; }
  .szpw-collection-panel { max-height: 230px; }
  .szpw-kpi-grid { grid-template-columns: repeat(2, minmax(0,1fr)); }
  .szpw-queue-row { grid-template-columns: 22px minmax(0,1fr) 86px; }
  .szpw-queue-row > select:nth-of-type(2), .szpw-queue-actions { grid-column: 2 / -1; }
  .szpw-worker-machine .szpw-queue-row { grid-template-columns: 22px minmax(0,1fr) 86px; }
}

@media (max-width: 620px) {
  :root { --szpw-drawer-collapsed: 42px; }
  .szpw-minibar { grid-template-columns: auto minmax(0,1fr) auto; padding: 0 9px; }
  .szpw-counts { display: none; }
  .szpw-minibar-title span { display: none; }
  .szpw-body { display: block; }
  .szpw-nav { height: 56px; display: flex; align-items: center; gap: 4px; padding: 6px; border-right: 0; border-bottom: 1px solid var(--szpw-line); overflow-x: auto; overflow-y: hidden; }
  .szpw-tab { width: 52px; min-width: 52px; margin: 0; }
  .szpw-main { height: calc(100% - 56px); }
  .szpw-toolbar { align-items: flex-start; padding: 8px 9px; }
  .szpw-toolbar-copy p { display: none; }
  .szpw-toolbar-actions { gap: 5px; }
  .szpw-content { padding: 9px; }
  .szpw-form-grid, .szpw-form-grid.three { grid-template-columns: 1fr; }
  .szpw-form-grid .span-all { grid-column: auto; }
  .szpw-grid.cards { grid-template-columns: 1fr; }
  .szpw-result-preview { height: 180px; }
  .szpw-size-row { grid-template-columns: minmax(0,1fr) 34px minmax(0,1fr); }
  .szpw-modal-layer { padding-left: 0; padding-right: 0; }
  .szpw-modal { border-left: 0; border-right: 0; }
  .szpw-sheet-row { grid-template-columns: 1fr 1fr auto; }
  .szpw-job-item { grid-template-columns: auto minmax(0,1fr) 58px; }
  .szpw-worker-shell { width: calc(100% - 16px); padding-top: 10px; }
  .szpw-worker-header { align-items: flex-start; }
  .szpw-worker-machine .szpw-queue-row { grid-template-columns: 20px minmax(0,1fr); }
  .szpw-worker-machine .szpw-queue-row select,
  .szpw-worker-machine .szpw-queue-actions { grid-column: 2; }
}

@media (prefers-reduced-motion: reduce) {
  .szpw-shell, .szpw-chevron svg, .szpw-button, .szpw-icon-button, .szpw-modal, .szpw-toast { transition: none !important; animation: none !important; }
}

.szpw-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}
.szpw-button svg { width: 14px; height: 14px; flex: 0 0 auto; margin: 0; }
html.szpw-drawer-open .szpw-editor-capture-fallback { display: none; }

/* ======================================================================
   Sheetzer Parts & Production mobile application shell — 20260819-v41
   The desktop drawer keeps its existing layout. The rules below turn the
   same workspace into an accessible bottom sheet / landscape side sheet.
   ====================================================================== */

.szpw-drawer-backdrop {
  display: none;
}

.szpw-shell.is-dragging {
  transition: none !important;
  transform: translateY(var(--szpw-drawer-drag, 0px));
  user-select: none;
}

.szpw-modal-open {
  overscroll-behavior: none;
}

[data-szpw-modal-background-inert="true"] {
  pointer-events: none !important;
  user-select: none !important;
}

.szpw-modal[aria-busy="true"] {
  cursor: wait;
}

.szpw-modal[aria-busy="true"] .szpw-modal-body {
  opacity: .72;
  pointer-events: none;
}

.szpw-minibar-main:focus-visible,
.szpw-window-button:focus-visible,
.szpw-chevron:focus-visible,
.szpw-tab:focus-visible,
.szpw-button:focus-visible,
.szpw-icon-button:focus-visible,
.szpw-collection-select:focus-visible,
.szpw-field :is(input, select, textarea):focus-visible,
.szpw-input:focus-visible {
  outline: 2px solid var(--szpw-accent-2);
  outline-offset: 2px;
}

/* Tablet touch pass. Mouse-driven desktop windows are excluded. */
@media (min-width: 621px) and (max-width: 900px) and (pointer: coarse) {
  :root {
    --szpw-drawer-collapsed: 52px;
  }

  .szpw-shell {
    width: calc(100vw - 16px);
    height: min(84dvh, 860px);
    border-radius: 22px 22px 0 0;
  }

  .szpw-minibar {
    height: var(--szpw-drawer-collapsed);
    padding-inline: 16px;
  }

  .szpw-body {
    grid-template-columns: 112px minmax(0, 1fr);
  }

  .szpw-nav {
    padding: 12px 8px;
  }

  .szpw-tab {
    min-height: 58px;
    grid-template-columns: 34px minmax(0, 1fr);
    gap: 8px;
    padding: 7px;
  }

  .szpw-tab b {
    display: block;
    font-size: 10px;
  }

  .szpw-tab small {
    display: none;
  }

  .szpw-button,
  .szpw-icon-button,
  .szpw-field :is(input, select, textarea),
  .szpw-input,
  .szpw-collection-select {
    min-height: 44px;
  }

  .szpw-icon-button {
    width: 44px;
    height: 44px;
  }

  .szpw-content {
    padding: 16px;
  }
}

/* Phone portrait / normal phone widths. */
@media (max-width: 620px) {
  :root {
    --szpw-drawer-collapsed: 56px;
    --szpw-mobile-edge: 10px;
    --szpw-mobile-dock-offset: calc(var(--eng-mobile-dock-h, 76px) + var(--eng-safe-bottom, env(safe-area-inset-bottom, 0px)) + 14px);
  }

  html.szpw-drawer-minimized #szpw-root {
    right: var(--szpw-mobile-edge);
    bottom: var(--szpw-mobile-dock-offset);
    left: var(--szpw-mobile-edge);
    display: flex;
    justify-content: center;
    padding: 0;
  }

  html.szpw-drawer-open #szpw-root {
    right: 0;
    bottom: 0;
    left: 0;
    padding: 0;
  }

  .szpw-drawer-backdrop {
    position: fixed;
    z-index: 0;
    inset: 0;
    width: 100%;
    height: 100%;
    padding: 0;
    border: 0;
    background: rgba(2, 5, 6, .54);
    opacity: 0;
    pointer-events: none;
    backdrop-filter: blur(4px);
    transition: opacity .2s ease;
  }

  html.szpw-drawer-open .szpw-drawer-backdrop {
    display: block;
    opacity: 1;
    pointer-events: auto;
  }

  .szpw-shell {
    position: relative;
    z-index: 1;
    width: 100%;
    height: min(920px, calc(var(--editor-vvh, 100dvh) - var(--eng-docbar-h, 56px) - 8px));
    max-height: calc(var(--editor-vvh, 100dvh) - 8px);
    margin: 0;
    border: 1px solid rgba(179, 205, 194, .28);
    border-bottom: 0;
    border-radius: 26px 26px 0 0;
    background:
      radial-gradient(circle at 16% -8%, rgba(255, 99, 0, .11), transparent 32%),
      var(--szpw-bg);
    box-shadow: 0 -28px 76px rgba(0, 0, 0, .62);
    transform: translateY(0);
    transition: height .24s cubic-bezier(.2,.8,.2,1), transform .24s cubic-bezier(.2,.8,.2,1), box-shadow .24s ease;
  }

  .szpw-shell.is-minimized {
    width: min(292px, calc(100vw - 28px));
    height: var(--szpw-drawer-collapsed);
    margin: 0 auto;
    overflow: visible;
    border: 1px solid rgba(179, 205, 194, .3);
    border-radius: 18px;
    background: rgba(13, 20, 18, .96);
    box-shadow:
      0 15px 36px rgba(0, 0, 0, .45),
      inset 0 1px rgba(255,255,255,.035);
    backdrop-filter: blur(22px) saturate(1.18);
  }

  html[data-theme="light"] .szpw-shell.is-minimized,
  html.light-layout .szpw-shell.is-minimized {
    background: rgba(255, 255, 255, .97);
  }

  .szpw-minibar {
    position: relative;
    height: var(--szpw-drawer-collapsed);
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 10px;
    padding: 7px 10px 3px 14px;
    border-bottom: 1px solid var(--szpw-line);
    background: rgba(15, 22, 19, .96);
    cursor: grab;
    touch-action: none;
  }

  .szpw-minibar:active {
    cursor: grabbing;
  }

  .szpw-minibar-main {
    min-width: 0;
    width: 100%;
    height: 100%;
    grid-template-columns: auto minmax(0, 1fr) auto;
    gap: 10px;
    padding: 0 2px 0 4px;
    border-radius: 13px;
    touch-action: manipulation;
  }

  .szpw-shell.is-minimized .szpw-minibar-main {
    grid-template-columns: auto minmax(0, 1fr);
    gap: 8px;
    padding-left: 2px;
  }

  .szpw-minibar::before {
    content: "";
    position: absolute;
    top: 6px;
    left: 50%;
    width: 38px;
    height: 4px;
    border-radius: 999px;
    background: rgba(180, 203, 193, .28);
    transform: translateX(-50%);
  }

  .szpw-shell.is-minimized .szpw-minibar {
    height: var(--szpw-drawer-collapsed);
    padding: 0 6px 0 12px;
    border: 0;
    border-radius: inherit;
    background: transparent;
  }

  .szpw-shell.is-minimized .szpw-minibar::before {
    display: none;
  }

  .szpw-grip {
    width: 36px;
    height: 4px;
    box-shadow: 0 0 12px rgba(255, 99, 0, .24);
  }

  .szpw-minibar-title {
    width: 100%;
    min-width: 0;
    display: grid;
    grid-template-rows: auto auto;
    align-content: center;
    align-items: start;
    gap: 1px;
    padding-top: 3px;
  }

  .szpw-minibar-title strong {
    width: 100%;
    overflow: hidden;
    font-size: 14px;
    font-weight: 780;
    line-height: 1.15;
    letter-spacing: -.015em;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .szpw-minibar-title span {
    display: block;
    width: 100%;
    max-width: none;
    overflow: hidden;
    font-size: 9px;
    line-height: 1.2;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .szpw-shell.is-minimized .szpw-minibar-title {
    display: flex;
    align-items: center;
    gap: 0;
    padding-top: 0;
  }

  .szpw-shell.is-minimized .szpw-minibar-title span,
  .szpw-counts {
    display: none;
  }

  .szpw-chevron {
    width: 46px;
    height: 46px;
    min-height: 46px;
    border: 1px solid transparent;
    border-radius: 14px;
  }

  .szpw-chevron:active,
  .szpw-chevron:focus-visible {
    border-color: rgba(255, 99, 0, .28);
    background: rgba(255, 99, 0, .1);
    color: var(--szpw-accent-2);
  }

  .szpw-chevron svg {
    width: 18px;
    height: 18px;
    opacity: .86;
    stroke-width: 2;
  }

  .szpw-body {
    height: calc(100% - var(--szpw-drawer-collapsed));
    display: block;
    min-height: 0;
  }

  .szpw-nav {
    height: 78px;
    display: flex;
    align-items: stretch;
    gap: 6px;
    padding: 7px 8px;
    border-right: 0;
    border-bottom: 1px solid var(--szpw-line);
    background: rgba(17, 23, 21, .98);
    overflow-x: auto;
    overflow-y: hidden;
    scroll-padding-inline: 8px;
    scroll-snap-type: x proximity;
    scrollbar-width: none;
    overscroll-behavior-x: contain;
    -webkit-overflow-scrolling: touch;
  }

  .szpw-nav::-webkit-scrollbar {
    display: none;
  }

  .szpw-brand,
  .szpw-account-state {
    display: none;
  }

  .szpw-tab {
    position: relative;
    width: 74px;
    min-width: 74px;
    min-height: 64px;
    display: grid;
    grid-template-columns: 1fr;
    grid-template-rows: 31px 15px;
    align-content: center;
    justify-items: center;
    gap: 3px;
    margin: 0;
    padding: 5px 4px;
    border-radius: 15px;
    text-align: center;
    scroll-snap-align: start;
  }

  .szpw-tab-icon {
    width: 31px;
    height: 31px;
    border-radius: 10px;
  }

  .szpw-tab-icon svg {
    width: 17px;
    height: 17px;
  }

  .szpw-tab b {
    display: block;
    max-width: 100%;
    overflow: hidden;
    font-size: 9.5px;
    line-height: 1;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .szpw-tab small {
    position: absolute;
    top: 5px;
    right: 6px;
    min-width: 18px;
    height: 18px;
    display: grid;
    place-items: center;
    padding-inline: 4px;
    border: 1px solid var(--szpw-line);
    border-radius: 999px;
    color: var(--szpw-muted);
    background: var(--szpw-panel-2);
    font-size: 8px;
    line-height: 1;
  }

  .szpw-tab.is-active {
    border-color: rgba(255, 99, 0, .38);
    background: linear-gradient(180deg, rgba(255, 99, 0, .15), rgba(255, 99, 0, .07));
  }

  .szpw-tab.is-active small {
    border-color: rgba(255, 99, 0, .34);
    color: #ffd8ca;
    background: rgba(255, 99, 0, .16);
  }

  .szpw-main {
    height: calc(100% - 78px);
    min-height: 0;
  }

  .szpw-toolbar {
    position: sticky;
    z-index: 5;
    top: 0;
    min-height: 68px;
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 9px;
    padding: 9px 10px;
    border-bottom: 1px solid var(--szpw-line);
    background: rgba(16, 23, 20, .94);
    backdrop-filter: blur(20px) saturate(1.16);
  }

  .szpw-toolbar-copy h2 {
    font-size: 16px;
    line-height: 1.15;
  }

  .szpw-toolbar-copy p {
    display: -webkit-box;
    margin-top: 4px;
    overflow: hidden;
    font-size: 9px;
    line-height: 1.3;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
  }

  .szpw-toolbar-actions {
    max-width: 54vw;
    flex-wrap: nowrap;
    justify-content: flex-start;
    gap: 6px;
    overflow-x: auto;
    scroll-snap-type: x proximity;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
  }

  .szpw-toolbar-actions::-webkit-scrollbar {
    display: none;
  }

  .szpw-toolbar-actions > * {
    flex: 0 0 auto;
    scroll-snap-align: end;
  }

  .szpw-content {
    padding: 12px 10px calc(22px + env(safe-area-inset-bottom, 0px));
    overflow-x: hidden;
    overflow-y: auto;
    overscroll-behavior: contain;
    scroll-padding-bottom: 24px;
    -webkit-overflow-scrolling: touch;
  }

  .szpw-grid,
  .szpw-stack {
    gap: 12px;
  }

  .szpw-grid.two,
  .szpw-grid.cards,
  .szpw-form-grid,
  .szpw-form-grid.three {
    grid-template-columns: 1fr;
  }

  .szpw-form-grid .span-all {
    grid-column: auto;
  }

  .szpw-panel,
  .szpw-result-card,
  .szpw-material-card,
  .szpw-job-card,
  .szpw-machine-card,
  .szpw-worker-card,
  .szpw-empty {
    border-radius: 18px;
    box-shadow: inset 0 1px rgba(255,255,255,.018);
  }

  .szpw-panel-head {
    min-height: 52px;
    padding: 6px 7px 6px 13px;
  }

  .szpw-panel-head h3 {
    font-size: 13px;
  }

  .szpw-collection-panel {
    max-height: none;
    overflow: visible;
  }

  .szpw-collection-panel .szpw-panel-body {
    padding: 8px;
  }

  .szpw-collection-list {
    display: flex;
    gap: 7px;
    overflow-x: auto;
    scroll-padding-inline: 1px;
    scroll-snap-type: x proximity;
    scrollbar-width: none;
    overscroll-behavior-x: contain;
    -webkit-overflow-scrolling: touch;
  }

  .szpw-collection-list::-webkit-scrollbar {
    display: none;
  }

  .szpw-collection-row {
    flex: 0 0 auto;
    grid-template-columns: minmax(118px, auto) auto auto;
    min-height: 50px;
    padding: 3px;
    border-radius: 14px;
    scroll-snap-align: start;
  }

  .szpw-collection-select {
    min-height: 44px;
    padding: 7px 9px;
    border-radius: 11px;
  }

  .szpw-collection-select b {
    font-size: 11px;
  }

  .szpw-collection-select small {
    font-size: 9px;
  }

  .szpw-button,
  .szpw-icon-button,
  .szpw-field :is(input, select, textarea),
  .szpw-input,
  .szpw-collection-select {
    min-height: 46px;
  }

  .szpw-button {
    padding: 8px 13px;
    border-radius: 13px;
    font-size: 11px;
  }

  .szpw-button.compact {
    min-height: 44px;
    padding: 7px 10px;
    border-radius: 12px;
    font-size: 10px;
  }

  .szpw-icon-button {
    width: 46px;
    min-width: 46px;
    height: 46px;
    border-radius: 13px;
  }

  .szpw-icon-button svg,
  .szpw-button svg {
    width: 17px;
    height: 17px;
  }

  .szpw-field {
    gap: 6px;
  }

  .szpw-field > span,
  .szpw-field > label {
    font-size: 10px;
  }

  .szpw-field input,
  .szpw-field select,
  .szpw-field textarea,
  .szpw-input {
    padding: 10px 11px;
    border-radius: 12px;
    font-size: 16px;
  }

  .szpw-field textarea {
    min-height: 108px;
  }

  .szpw-check {
    min-height: 44px;
    gap: 10px;
    font-size: 12px;
  }

  .szpw-check input {
    width: 20px;
    height: 20px;
  }

  .szpw-result-preview {
    height: 190px;
    padding: 12px;
  }

  .szpw-result-body,
  .szpw-card-body {
    padding: 12px;
  }

  .szpw-result-name {
    grid-template-columns: minmax(0, 1fr) 46px;
    gap: 8px;
  }

  .szpw-result-meta {
    gap: 6px;
    font-size: 9px;
  }

  .szpw-result-meta span {
    padding: 5px 8px;
  }

  .szpw-size-row {
    grid-template-columns: minmax(0, 1fr) 46px minmax(0, 1fr);
    gap: 7px;
  }

  .szpw-result-actions {
    gap: 8px;
  }

  .szpw-card-head {
    gap: 9px;
    padding: 12px;
  }

  .szpw-card-head h3 {
    font-size: 14px;
  }

  .szpw-card-head p {
    font-size: 10px;
    line-height: 1.4;
  }

  .szpw-card-actions {
    flex: 0 0 auto;
    gap: 6px;
  }

  .szpw-machine-card .szpw-card-head {
    flex-wrap: wrap;
  }

  .szpw-machine-card .szpw-card-actions {
    width: 100%;
    overflow-x: auto;
    scrollbar-width: none;
  }

  .szpw-machine-card .szpw-card-actions::-webkit-scrollbar {
    display: none;
  }

  .szpw-tag {
    padding: 6px 9px;
    border-radius: 9px;
    font-size: 10px;
  }

  .szpw-job-items {
    max-height: 46dvh;
    gap: 8px;
  }

  .szpw-job-item {
    grid-template-columns: auto minmax(0, 1fr) 76px;
    min-height: 52px;
    gap: 8px;
    padding: 8px;
    border-radius: 12px;
  }

  .szpw-job-item b {
    font-size: 11px;
  }

  .szpw-kpi-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
  }

  .szpw-kpi {
    min-height: 72px;
    display: grid;
    align-content: center;
    padding: 10px;
    border-radius: 13px;
  }

  .szpw-kpi b {
    font-size: 18px;
  }

  .szpw-kpi span {
    font-size: 9px;
  }

  .szpw-queue {
    gap: 9px;
  }

  .szpw-queue-row {
    grid-template-columns: 32px minmax(0, 1fr) auto;
    gap: 8px;
    padding: 9px;
    border-radius: 14px;
  }

  .szpw-queue-order {
    width: 32px;
    height: 32px;
    display: grid;
    place-items: center;
    border: 1px solid var(--szpw-line);
    border-radius: 10px;
    background: var(--szpw-panel-3);
    font-size: 10px;
  }

  .szpw-queue-copy b {
    font-size: 11px;
  }

  .szpw-queue-copy small {
    font-size: 9px;
  }

  .szpw-queue-row > select:nth-of-type(1),
  .szpw-queue-row > select:nth-of-type(2),
  .szpw-queue-actions {
    grid-column: 2 / -1;
  }

  .szpw-queue-actions {
    justify-content: flex-end;
    gap: 6px;
  }

  .szpw-status {
    min-height: 30px;
    padding: 5px 8px;
    font-size: 9px;
  }

  .szpw-note {
    padding: 12px;
    border-radius: 13px;
    font-size: 10px;
    line-height: 1.55;
  }

  .szpw-empty {
    min-height: 210px;
    padding: 24px 18px;
  }

  .szpw-empty strong {
    font-size: 16px;
  }

  .szpw-empty p {
    font-size: 11px;
    line-height: 1.5;
  }

  .szpw-editor-capture-fallback {
    display: none !important;
  }

  .szpw-modal-layer {
    top: var(--editor-vv-top, 0px);
    bottom: auto;
    height: var(--editor-vvh, 100dvh);
    align-items: end;
    padding: 8px 0 0;
    background: rgba(0, 0, 0, .64);
    backdrop-filter: blur(8px);
  }

  .szpw-modal {
    width: 100%;
    max-height: calc(var(--editor-vvh, 100dvh) - 8px);
    border-right: 0;
    border-left: 0;
    border-radius: 26px 26px 0 0;
    padding-bottom: env(safe-area-inset-bottom, 0px);
    background:
      radial-gradient(circle at 18% -10%, rgba(255, 99, 0, .11), transparent 32%),
      var(--szpw-bg);
  }

  .szpw-modal::before {
    content: "";
    flex: 0 0 auto;
    align-self: center;
    width: 40px;
    height: 4px;
    margin: 8px auto 2px;
    border-radius: 999px;
    background: var(--szpw-line-strong);
  }

  .szpw-modal-head {
    position: sticky;
    z-index: 3;
    top: 0;
    min-height: 64px;
    padding: 8px 9px 9px 14px;
    background: rgba(17, 23, 21, .96);
    backdrop-filter: blur(18px);
  }

  .szpw-modal-head h2 {
    font-size: 18px;
    letter-spacing: -.02em;
  }

  .szpw-modal-head p {
    margin-top: 3px;
    font-size: 10px;
    line-height: 1.35;
  }

  .szpw-modal-body {
    padding: 14px 12px 18px;
    overscroll-behavior: contain;
    scroll-padding-bottom: 24px;
    -webkit-overflow-scrolling: touch;
  }

  .szpw-modal-foot {
    position: sticky;
    z-index: 3;
    bottom: 0;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
    padding: 10px 12px calc(10px + env(safe-area-inset-bottom, 0px));
    background: rgba(17, 23, 21, .97);
    backdrop-filter: blur(18px);
  }

  .szpw-modal-foot .szpw-button {
    width: 100%;
    min-height: 48px;
  }

  html.editor-keyboard-open[data-editor-keyboard-owner="parts"] .szpw-modal-layer {
    padding-top: 0;
  }

  html.editor-keyboard-open[data-editor-keyboard-owner="parts"] .szpw-modal {
    max-height: var(--editor-vvh, 100dvh);
    border-radius: 18px 18px 0 0;
  }

  .szpw-toast-stack {
    right: 10px;
    bottom: calc(var(--szpw-mobile-dock-offset) + var(--szpw-drawer-collapsed) + 10px);
    left: 10px;
    justify-items: center;
  }

  html.szpw-drawer-open .szpw-toast-stack,
  html.szpw-modal-open .szpw-toast-stack {
    bottom: calc(16px + env(safe-area-inset-bottom, 0px));
  }

  .szpw-toast {
    width: min(420px, 100%);
    padding: 12px 14px;
    border-radius: 15px;
  }

  .szpw-toast b {
    font-size: 12px;
  }

  .szpw-toast span {
    margin-top: 3px;
    font-size: 10px;
  }

  body.szpw-worker-page {
    min-height: 100dvh;
  }

  .szpw-worker-shell {
    width: calc(100% - 16px);
    padding: max(10px, env(safe-area-inset-top, 0px)) 0 calc(34px + env(safe-area-inset-bottom, 0px));
  }

  .szpw-worker-header {
    position: sticky;
    z-index: 8;
    top: 0;
    align-items: center;
    margin: 0 -4px 12px;
    padding: 8px 4px;
    background: rgba(11, 15, 14, .9);
    backdrop-filter: blur(18px);
  }

  .szpw-worker-mark {
    width: 46px;
    height: 46px;
    border-radius: 14px;
  }

  .szpw-worker-header h1 {
    font-size: 18px;
  }

  .szpw-worker-header p {
    font-size: 10px;
  }

  .szpw-worker-login {
    width: 100%;
    margin: 8vh auto 0;
  }

  .szpw-worker-machine .szpw-queue-row {
    grid-template-columns: 32px minmax(0, 1fr);
  }

  .szpw-worker-machine .szpw-queue-row select,
  .szpw-worker-machine .szpw-queue-actions {
    grid-column: 2;
  }
}

@media (max-width: 380px) and (orientation: portrait) {
  :root {
    --szpw-mobile-edge: 7px;
  }

  .szpw-shell.is-minimized {
    width: min(278px, calc(100vw - 20px));
  }

  .szpw-minibar {
    gap: 7px;
    padding-left: 10px;
  }

  .szpw-grip {
    width: 30px;
  }

  .szpw-minibar-title strong {
    font-size: 13px;
  }

  .szpw-toolbar {
    grid-template-columns: 1fr;
    align-items: start;
  }

  .szpw-toolbar-actions {
    width: 100%;
    max-width: none;
  }

  .szpw-toolbar-actions .szpw-button {
    flex: 1 0 auto;
  }

  .szpw-tab {
    width: 70px;
    min-width: 70px;
  }

  .szpw-size-row {
    grid-template-columns: minmax(0, 1fr) 42px minmax(0, 1fr);
    gap: 5px;
  }

  .szpw-icon-button {
    width: 44px;
    min-width: 44px;
    height: 44px;
    min-height: 44px;
  }
}

/* Short phone landscape: a right-side production sheet preserves canvas
   height and avoids colliding with Engineering's left navigation rail. */
@media (max-width: 932px) and (max-height: 520px) and (orientation: landscape) {
  :root {
    --szpw-drawer-collapsed: 52px;
  }

  html.szpw-drawer-minimized #szpw-root {
    right: max(10px, env(safe-area-inset-right, 0px));
    bottom: max(10px, env(safe-area-inset-bottom, 0px));
    left: auto;
    width: min(300px, 46vw);
  }

  html.szpw-drawer-open #szpw-root {
    top: var(--eng-docbar-h, calc(48px + env(safe-area-inset-top, 0px)));
    right: 0;
    bottom: 0;
    left: auto;
    width: min(590px, 76vw);
  }

  .szpw-drawer-backdrop {
    position: fixed;
    z-index: 0;
    inset: 0;
    width: 100%;
    height: 100%;
    padding: 0;
    border: 0;
    background: rgba(2, 5, 6, .48);
    opacity: 0;
    pointer-events: none;
    backdrop-filter: blur(3px);
  }

  html.szpw-drawer-open .szpw-drawer-backdrop {
    display: block;
    opacity: 1;
    pointer-events: auto;
  }

  .szpw-shell {
    position: relative;
    z-index: 1;
    width: 100%;
    height: 100%;
    max-height: none;
    margin: 0;
    border: 1px solid var(--szpw-line-strong);
    border-right: 0;
    border-bottom: 0;
    border-radius: 24px 0 0 0;
    box-shadow: -24px 0 64px rgba(0, 0, 0, .54);
  }

  .szpw-shell.is-minimized {
    width: 100%;
    height: var(--szpw-drawer-collapsed);
    border: 1px solid var(--szpw-line-strong);
    border-radius: 17px;
    box-shadow: 0 14px 34px rgba(0,0,0,.42);
  }

  .szpw-minibar {
    height: var(--szpw-drawer-collapsed);
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 8px;
    padding: 0 6px 0 12px;
    touch-action: none;
  }

  .szpw-minibar::before,
  .szpw-counts,
  .szpw-minibar-title span {
    display: none;
  }

  .szpw-minibar-main {
    min-width: 0;
    height: 100%;
    grid-template-columns: auto minmax(0, 1fr);
    gap: 8px;
    padding: 0 2px;
  }

  .szpw-minibar-title strong {
    font-size: 13px;
  }

  .szpw-chevron {
    width: 42px;
    height: 42px;
    min-height: 42px;
  }

  .szpw-body {
    height: calc(100% - var(--szpw-drawer-collapsed));
    display: grid;
    grid-template-columns: 90px minmax(0, 1fr);
  }

  .szpw-nav {
    height: auto;
    display: block;
    padding: 6px;
    border-right: 1px solid var(--szpw-line);
    border-bottom: 0;
    overflow-x: hidden;
    overflow-y: auto;
  }

  .szpw-brand,
  .szpw-account-state {
    display: none;
  }

  .szpw-tab {
    width: 100%;
    min-width: 0;
    min-height: 52px;
    display: grid;
    grid-template-columns: 30px minmax(0, 1fr);
    gap: 6px;
    margin: 2px 0;
    padding: 5px;
    border-radius: 12px;
  }

  .szpw-tab b {
    display: block;
    overflow: hidden;
    font-size: 8.5px;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .szpw-tab small {
    display: none;
  }

  .szpw-main {
    height: 100%;
  }

  .szpw-toolbar {
    min-height: 56px;
    padding: 6px 8px;
  }

  .szpw-toolbar-copy h2 {
    font-size: 14px;
  }

  .szpw-toolbar-copy p {
    display: none;
  }

  .szpw-toolbar-actions {
    flex-wrap: nowrap;
    overflow-x: auto;
    scrollbar-width: none;
  }

  .szpw-content {
    padding: 9px 9px calc(12px + env(safe-area-inset-bottom, 0px));
  }

  .szpw-grid.two,
  .szpw-grid.cards,
  .szpw-form-grid,
  .szpw-form-grid.three {
    grid-template-columns: 1fr;
  }

  .szpw-button,
  .szpw-icon-button,
  .szpw-field :is(input, select, textarea),
  .szpw-input,
  .szpw-collection-select {
    min-height: 42px;
  }

  .szpw-icon-button {
    width: 42px;
    min-width: 42px;
    height: 42px;
  }

  .szpw-field :is(input, select, textarea),
  .szpw-input {
    font-size: 16px;
  }

  .szpw-collection-panel {
    max-height: 132px;
  }

  .szpw-result-preview {
    height: 150px;
  }

  .szpw-modal-layer {
    top: var(--editor-vv-top, 0px);
    bottom: auto;
    height: var(--editor-vvh, 100dvh);
    align-items: stretch;
    justify-items: end;
    padding: 0;
  }

  .szpw-modal,
  .szpw-modal.wide {
    width: min(620px, 78vw);
    height: 100%;
    max-height: none;
    border-top: 0;
    border-right: 0;
    border-bottom: 0;
    border-radius: 22px 0 0 22px;
  }

  .szpw-modal-foot {
    padding-bottom: max(8px, env(safe-area-inset-bottom, 0px));
  }

  .szpw-toast-stack {
    right: calc(min(590px, 76vw) + 10px);
    bottom: 10px;
    left: auto;
  }

  html.szpw-drawer-minimized .szpw-toast-stack {
    right: 10px;
    bottom: calc(var(--szpw-drawer-collapsed) + 18px);
  }

  .szpw-editor-capture-fallback {
    display: none !important;
  }
}

@media (prefers-reduced-motion: reduce) {
  .szpw-drawer-backdrop,
  .szpw-shell,
  .szpw-minibar,
  .szpw-chevron svg,
  .szpw-button,
  .szpw-icon-button,
  .szpw-modal,
  .szpw-toast {
    transition-duration: .01ms !important;
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
  }
}

/* Mobile surface arbitration — the launcher yields while another Engineering
   sheet, panel, command console, or software keyboard owns the screen. */
@media (max-width: 620px),
       (max-width: 932px) and (max-height: 520px) and (orientation: landscape) {
  #szpw-root[data-drawer-state="minimized"] {
    transition: opacity .16s ease, transform .18s ease, visibility .16s ease;
  }

  body:is(
    .engineer-mobile-sheet-open,
    .engineer-tool-family-open,
    .engineer-command-open,
    .engineer-left-open,
    .engineer-right-open
  ) #szpw-root[data-drawer-state="minimized"],
  html.editor-keyboard-open:not(.szpw-drawer-open) #szpw-root[data-drawer-state="minimized"] {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transform: translateY(12px);
  }
}

/* ======================================================================
   Parts & Production mobile hardening — 20260819-v41
   Mobile-only interaction polish; desktop drawer geometry is unchanged.
   ====================================================================== */
@media (max-width: 620px),
       (max-width: 932px) and (max-height: 520px) and (orientation: landscape) {
  html.szpw-drawer-open,
  html.szpw-drawer-open body,
  html.szpw-modal-open,
  html.szpw-modal-open body {
    overflow: hidden;
    overscroll-behavior: none;
  }

  .szpw-shell.is-dragging .szpw-body {
    pointer-events: none;
  }

  .szpw-minibar-main,
  .szpw-window-button,
  .szpw-chevron,
  .szpw-tab,
  .szpw-button,
  .szpw-icon-button,
  .szpw-collection-select {
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
  }

  .szpw-minibar,
  .szpw-modal-head {
    -webkit-user-select: none;
    user-select: none;
  }

  .szpw-content,
  .szpw-modal-body,
  .szpw-nav,
  .szpw-toolbar-actions {
    overscroll-behavior: contain;
  }

  .szpw-modal-layer {
    overscroll-behavior: none;
  }

  .szpw-shell[role="dialog"] {
    outline: none;
  }
}

@media (forced-colors: active) and (max-width: 620px) {
  .szpw-shell,
  .szpw-modal,
  .szpw-minibar,
  .szpw-toolbar,
  .szpw-card,
  .szpw-result-card,
  .szpw-job-item,
  .szpw-machine-card {
    border: 1px solid CanvasText !important;
    background: Canvas !important;
    color: CanvasText !important;
    box-shadow: none !important;
    backdrop-filter: none !important;
  }
}

/* ======================================================================
   Parts & Production app-depth pass — 20260819-v42
   Uses the measured visual viewport for the phone dialog, resolves safe-area
   offsets at the launcher itself, and gives short-landscape navigation enough
   width for readable labels. Desktop rules are not touched.
   ====================================================================== */
@media (max-width: 620px) {
  html.szpw-drawer-minimized #szpw-root {
    --szpw-mobile-dock-offset: calc(
      var(--eng-mobile-dock-h, 76px) +
      var(--eng-safe-bottom, env(safe-area-inset-bottom, 0px)) +
      max(8px, var(--eng-safe-bottom, env(safe-area-inset-bottom, 0px))) +
      6px
    );
  }

  html.szpw-drawer-open #szpw-root {
    top: var(--editor-vv-top, 0px);
    right: auto;
    bottom: auto;
    left: 0;
    width: var(--editor-vvw, 100vw);
    max-width: 100vw;
    height: var(--editor-vvh, 100dvh);
    display: flex;
    align-items: flex-end;
  }

  html.szpw-drawer-open .szpw-shell:not(.is-minimized) {
    width: var(--editor-vvw, 100vw);
    min-width: var(--editor-vvw, 100vw);
    max-width: var(--editor-vvw, 100vw);
    flex: 0 0 var(--editor-vvw, 100vw);
  }
}

@media (max-width: 932px) and (max-height: 520px) and (orientation: landscape) {
  .szpw-body {
    grid-template-columns: 112px minmax(0, 1fr);
  }

  .szpw-tab {
    grid-template-columns: 30px minmax(0, 1fr);
    gap: 7px;
    padding-inline: 7px;
  }

  .szpw-tab b {
    font-size: 9.5px;
    letter-spacing: -.01em;
  }
}

@media (max-width: 700px) and (max-height: 520px) and (orientation: landscape) {
  .szpw-body {
    grid-template-columns: 104px minmax(0, 1fr);
  }

  .szpw-tab {
    padding-inline: 6px;
  }
}

/* ======================================================================
   Parts & Production mobile QA repair — 20260819-v45
   Portrait phone toolbars use a dedicated action row. This keeps complete
   button labels visible instead of hiding the primary action in a horizontal
   overflow area at 390–430px widths. Desktop and short-landscape stay intact.
   ====================================================================== */
@media (max-width: 480px) and (orientation: portrait) {
  .szpw-toolbar {
    grid-template-columns: minmax(0, 1fr);
    align-items: start;
    gap: 8px;
  }

  .szpw-toolbar-actions {
    display: grid;
    grid-template-columns: minmax(100px, .8fr) minmax(0, 1.2fr);
    width: 100%;
    max-width: none;
    gap: 6px;
    overflow: visible;
    scroll-snap-type: none;
  }

  .szpw-toolbar-actions > * {
    width: 100%;
    min-width: 0;
    justify-content: center;
  }
}

/* ======================================================================
   Parts & Production mobile full-screen and nested-editor arbitration
   — 20260819-v46
   The active embedded editor owns the workspace launcher. The outer page
   yields its copy, preventing two Parts & production bars from overlapping.
   Open workspaces become true visual-viewport pages with separate minimize
   and close controls; minimized workspaces retain the compact launcher.
   ====================================================================== */
@media (max-width: 620px),
       (max-width: 932px) and (max-height: 520px) and (orientation: landscape) {
  html.szpw-drawer-open #szpw-root {
    top: var(--editor-vv-top, 0px);
    right: auto;
    bottom: auto;
    left: 0;
    width: var(--editor-vvw, 100vw);
    max-width: 100vw;
    height: var(--editor-vvh, 100dvh);
    max-height: var(--editor-vvh, 100dvh);
    display: flex;
    align-items: stretch;
    justify-content: stretch;
    padding: 0;
  }

  html.szpw-drawer-open .szpw-drawer-backdrop {
    display: none;
    opacity: 0;
    pointer-events: none;
    backdrop-filter: none;
  }

  html.szpw-drawer-open .szpw-shell:not(.is-minimized) {
    width: 100%;
    min-width: 0;
    max-width: none;
    height: 100%;
    min-height: 100%;
    max-height: none;
    flex: 1 1 auto;
    margin: 0;
    border: 0;
    border-radius: 0;
    box-shadow: none;
    transform: none;
  }

  .szpw-shell:not(.is-minimized) .szpw-minibar {
    cursor: default;
  }

  .szpw-shell:not(.is-minimized) .szpw-minibar::before {
    display: none;
  }

  .szpw-shell:not(.is-minimized) .szpw-window-actions {
    display: flex;
  }

  .szpw-shell:not(.is-minimized) .szpw-chevron {
    display: none;
  }

  .szpw-window-button {
    width: 44px;
    min-width: 44px;
    height: 44px;
    min-height: 44px;
    border-radius: 13px;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
  }

  .szpw-window-minimize {
    background: rgba(255, 255, 255, .035);
  }

  .szpw-window-close {
    color: #ffb8bf;
    background: rgba(255, 95, 109, .1);
  }

  .szpw-shell.is-minimized .szpw-minibar-controls {
    gap: 0;
  }

  .szpw-shell.is-minimized .szpw-window-actions {
    display: none;
  }

  .szpw-shell.is-minimized .szpw-chevron {
    display: grid;
  }
}

@media (max-width: 420px) and (orientation: portrait) {
  .szpw-shell:not(.is-minimized) .szpw-minibar {
    gap: 6px;
    padding-right: 7px;
    padding-left: 10px;
  }

  .szpw-shell:not(.is-minimized) .szpw-minibar-main {
    gap: 7px;
    padding-left: 0;
  }

  .szpw-shell:not(.is-minimized) .szpw-grip {
    width: 27px;
  }

  .szpw-shell:not(.is-minimized) .szpw-minibar-title strong {
    font-size: 13px;
  }

  .szpw-window-actions,
  .szpw-minibar-controls {
    gap: 5px;
  }

  .szpw-window-button {
    width: 42px;
    min-width: 42px;
    height: 42px;
    min-height: 42px;
  }
}


/* Temporary part sharing */
.szpw-share-link-modal {
  display: grid;
  grid-template-columns: minmax(240px, .9fr) minmax(300px, 1.1fr);
  gap: 16px;
  align-items: stretch;
}
.szpw-share-link-preview {
  min-height: 280px;
  height: 100%;
  border: 1px solid var(--szpw-line);
  border-radius: 14px;
}
.szpw-share-link-copy { display: grid; align-content: start; gap: 12px; min-width: 0; }
.szpw-share-link-row { display: grid; grid-template-columns: minmax(0,1fr) auto; gap: 8px; }
.szpw-share-link-row .szpw-input { min-width: 0; }
.szpw-share-privacy,
.szpw-share-storage-note {
  margin: 0;
  color: var(--szpw-muted);
  font-size: 10px;
  line-height: 1.6;
}

body.szpw-part-share-page {
  min-height: 100vh;
  margin: 0;
  color: var(--szpw-text);
  background:
    radial-gradient(circle at 12% -8%, rgba(255,99,0,.17), transparent 34%),
    radial-gradient(circle at 88% 4%, rgba(61,220,151,.08), transparent 30%),
    var(--szpw-bg);
  font: 500 14px/1.45 Manrope, Montserrat, Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}
.szpw-part-share-shell {
  width: min(1120px, calc(100% - 28px));
  min-height: 100vh;
  display: grid;
  place-items: center;
  margin: 0 auto;
  padding: max(24px, env(safe-area-inset-top)) 0 max(40px, env(safe-area-inset-bottom));
}
.szpw-share-card {
  width: 100%;
  overflow: hidden;
  border: 1px solid var(--szpw-line-strong);
  border-radius: 20px;
  background: linear-gradient(150deg, rgba(255,99,0,.035), transparent 34%), var(--szpw-panel);
  box-shadow: 0 28px 90px rgba(0,0,0,.42);
}
.szpw-share-header {
  min-height: 70px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 13px 16px;
  border-bottom: 1px solid var(--szpw-line);
  background: rgba(11,15,14,.58);
  backdrop-filter: blur(18px);
}
html[data-theme="light"] .szpw-share-header,
html.light-layout .szpw-share-header { background: rgba(255,255,255,.72); }
.szpw-share-brand {
  min-width: 0;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: inherit;
  text-decoration: none;
}
.szpw-share-logo {
  width: 40px;
  height: 40px;
  flex: 0 0 40px;
  display: block;
  object-fit: contain;
}
.szpw-share-brand > span:last-child { min-width: 0; display: grid; }
.szpw-share-brand strong { font-size: 14px; line-height: 1.2; }
.szpw-share-brand small { margin-top: 2px; color: var(--szpw-muted); font-size: 9px; }
.szpw-share-expiry {
  flex: 0 0 auto;
  padding: 6px 9px;
  border: 1px solid rgba(255,180,84,.32);
  border-radius: 999px;
  color: var(--szpw-warn);
  background: rgba(255,180,84,.08);
  font-size: 9px;
  font-weight: 800;
  letter-spacing: .03em;
}
.szpw-share-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.18fr) minmax(330px, .82fr);
  min-height: 560px;
}
.szpw-share-preview-wrap {
  min-width: 0;
  display: grid;
  place-items: center;
  padding: clamp(18px, 4vw, 44px);
  border-right: 1px solid var(--szpw-line);
  background:
    linear-gradient(45deg, rgba(255,255,255,.027) 25%, transparent 25%, transparent 75%, rgba(255,255,255,.027) 75%),
    linear-gradient(45deg, rgba(255,255,255,.027) 25%, transparent 25%, transparent 75%, rgba(255,255,255,.027) 75%),
    var(--szpw-panel-2);
  background-size: 24px 24px;
  background-position: 0 0, 12px 12px;
}
.szpw-share-preview {
  width: min(100%, 680px);
  height: min(62vh, 560px);
  min-height: 320px;
  border: 1px solid var(--szpw-line-strong);
  border-radius: 16px;
  background-color: rgba(255,255,255,.02);
  box-shadow: 0 18px 50px rgba(0,0,0,.18);
}
.szpw-share-preview svg { width: 100%; height: 100%; }
.szpw-share-details {
  min-width: 0;
  display: grid;
  align-content: center;
  gap: 18px;
  padding: clamp(20px, 3vw, 34px);
}
.szpw-share-eyebrow {
  display: inline-block;
  margin-bottom: 6px;
  color: var(--szpw-accent-2);
  font-size: 9px;
  font-weight: 850;
  letter-spacing: .12em;
  text-transform: uppercase;
}
.szpw-share-details h1 {
  margin: 0 0 10px;
  font-size: clamp(22px, 3vw, 34px);
  line-height: 1.1;
  overflow-wrap: anywhere;
}
.szpw-share-dimensions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0,1fr));
  gap: 9px;
}
.szpw-share-dimensions > div {
  padding: 12px;
  border: 1px solid var(--szpw-line);
  border-radius: 11px;
  background: var(--szpw-panel-2);
}
.szpw-share-dimensions small { display: block; color: var(--szpw-muted); font-size: 8px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.szpw-share-dimensions strong { display: block; margin-top: 4px; font-size: 14px; }
.szpw-share-import {
  display: grid;
  gap: 10px;
  padding: 14px;
  border: 1px solid var(--szpw-line-strong);
  border-radius: 14px;
  background: var(--szpw-panel-2);
}
.szpw-share-add { width: 100%; min-height: 42px; justify-content: center; }
.szpw-share-added { font-size: 10px; }
.szpw-share-state {
  min-height: min(560px, calc(100vh - 48px));
  display: grid;
  place-items: center;
  align-content: center;
  gap: 12px;
  padding: 36px;
  text-align: center;
}
.szpw-share-state h1 { margin: 4px 0 0; font-size: 24px; }
.szpw-share-state p { max-width: 480px; margin: 0; color: var(--szpw-muted); line-height: 1.6; }
.szpw-share-spinner {
  width: 34px;
  height: 34px;
  border: 3px solid var(--szpw-line-strong);
  border-top-color: var(--szpw-accent);
  border-radius: 50%;
  animation: szpw-share-spin .8s linear infinite;
}
@keyframes szpw-share-spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) {
  .szpw-inline-spinner,
  .szpw-share-spinner { animation-duration: 1.6s; }
}

@media (max-width: 760px) {
  .szpw-share-link-modal { grid-template-columns: 1fr; }
  .szpw-share-link-preview { min-height: 220px; height: 250px; }
  .szpw-share-link-row { grid-template-columns: 1fr; }
  .szpw-part-share-shell { width: 100%; padding: 0; place-items: stretch; }
  .szpw-share-card { min-height: 100vh; border-width: 0; border-radius: 0; box-shadow: none; }
  .szpw-share-header { min-height: 64px; padding: max(10px, env(safe-area-inset-top)) 12px 10px; }
  .szpw-share-expiry { font-size: 8px; }
  .szpw-share-layout { display: block; min-height: 0; }
  .szpw-share-preview-wrap { padding: 14px; border-right: 0; border-bottom: 1px solid var(--szpw-line); }
  .szpw-share-preview { height: min(46vh, 390px); min-height: 250px; border-radius: 13px; }
  .szpw-share-details { align-content: start; gap: 14px; padding: 18px 14px calc(24px + env(safe-area-inset-bottom)); }
  .szpw-share-details h1 { font-size: 24px; }
  .szpw-share-import { position: sticky; bottom: max(8px, env(safe-area-inset-bottom)); z-index: 2; box-shadow: 0 16px 40px rgba(0,0,0,.25); }
  .szpw-share-state { min-height: 100vh; border: 0; border-radius: 0; }
}

/* ======================================================================
   Parts collection exporter entry — 20260819-v51
   Gives every saved part the same full export studio used by the converter.
   ====================================================================== */
.szpw-result-actions {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 6px;
}
.szpw-result-actions > select {
  grid-column: 1;
  min-width: 0;
}
.szpw-result-export {
  grid-column: 1 / -1;
  width: 100%;
  min-height: 42px;
  display: grid;
  grid-template-columns: auto auto;
  grid-template-rows: auto auto;
  justify-content: center;
  align-items: center;
  column-gap: 7px;
  row-gap: 1px;
  padding: 7px 10px;
  text-align: left;
}
.szpw-result-export > svg {
  grid-row: 1 / 3;
  width: 16px;
  height: 16px;
}
.szpw-result-export > span {
  align-self: end;
  font-size: 11px;
  font-weight: 850;
  line-height: 1.15;
}
.szpw-result-export > small {
  align-self: start;
  color: rgba(255,255,255,.78);
  font-size: 7.5px;
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: .015em;
  white-space: nowrap;
}
.szpw-result-export.is-loading { cursor: progress; }
.szpw-result-export.is-loading > svg { animation: szpw-export-pulse .8s ease-in-out infinite alternate; }
@keyframes szpw-export-pulse { from { opacity: .45; transform: translateY(1px); } to { opacity: 1; transform: translateY(-1px); } }

@media (max-width: 620px),
       (max-width: 932px) and (max-height: 520px) and (orientation: landscape) {
  .szpw-result-actions {
    grid-template-columns: minmax(0, 1fr) 46px 46px;
    gap: 8px;
  }
  .szpw-result-export {
    min-height: 48px;
    padding: 8px 12px;
  }
  .szpw-result-export > span { font-size: 12px; }
  .szpw-result-export > small { font-size: 8px; }
}

/* ======================================================================
   Compact minimized collection launcher — 20260820-v53
   The minimized Parts & production workspace is a single unobtrusive
   bottom-left button on desktop and mobile. The expanded workspace keeps
   its existing full drawer/application behavior.
   ====================================================================== */
.szpw-launcher-icon {
  display: none;
}

#szpw-root[data-drawer-state="minimized"] {
  --szpw-launcher-size: 48px;
  --szpw-launcher-edge: 12px;
  top: auto !important;
  right: auto !important;
  bottom: max(var(--szpw-launcher-edge), env(safe-area-inset-bottom, 0px)) !important;
  left: max(var(--szpw-launcher-edge), env(safe-area-inset-left, 0px)) !important;
  width: var(--szpw-launcher-size) !important;
  min-width: 0 !important;
  max-width: var(--szpw-launcher-size) !important;
  height: var(--szpw-launcher-size) !important;
  min-height: 0 !important;
  max-height: var(--szpw-launcher-size) !important;
  display: block !important;
  padding: 0 !important;
  margin: 0 !important;
}

#szpw-root[data-drawer-state="minimized"] .szpw-drawer-backdrop,
#szpw-root[data-drawer-state="minimized"] .szpw-body {
  display: none !important;
}

#szpw-root[data-drawer-state="minimized"] .szpw-shell.is-minimized {
  width: 100% !important;
  min-width: 0 !important;
  max-width: 100% !important;
  height: 100% !important;
  min-height: 0 !important;
  max-height: 100% !important;
  margin: 0 !important;
  overflow: hidden !important;
  border: 1px solid rgba(177, 201, 191, .30) !important;
  border-radius: 15px !important;
  background:
    linear-gradient(145deg, rgba(255, 99, 0, .12), transparent 48%),
    rgba(13, 19, 17, .96) !important;
  box-shadow:
    0 10px 26px rgba(0, 0, 0, .34),
    inset 0 1px rgba(255, 255, 255, .045) !important;
  backdrop-filter: blur(18px) saturate(1.14);
  -webkit-backdrop-filter: blur(18px) saturate(1.14);
  transition:
    transform .16s ease,
    border-color .16s ease,
    background-color .16s ease,
    box-shadow .16s ease !important;
}

html[data-theme="light"] #szpw-root[data-drawer-state="minimized"] .szpw-shell.is-minimized,
html.light-layout #szpw-root[data-drawer-state="minimized"] .szpw-shell.is-minimized {
  border-color: rgba(26, 47, 38, .19) !important;
  background:
    linear-gradient(145deg, rgba(255, 99, 0, .10), transparent 48%),
    rgba(255, 255, 255, .97) !important;
  box-shadow:
    0 8px 22px rgba(19, 35, 28, .18),
    inset 0 1px rgba(255, 255, 255, .72) !important;
}

#szpw-root[data-drawer-state="minimized"] .szpw-minibar {
  position: relative !important;
  width: 100% !important;
  height: 100% !important;
  min-height: 0 !important;
  display: block !important;
  padding: 0 !important;
  border: 0 !important;
  border-radius: inherit !important;
  background: transparent !important;
  cursor: pointer !important;
  touch-action: manipulation !important;
}

#szpw-root[data-drawer-state="minimized"] .szpw-minibar::before {
  display: none !important;
}

#szpw-root[data-drawer-state="minimized"] .szpw-minibar-main {
  position: relative;
  width: 100% !important;
  min-width: 0 !important;
  height: 100% !important;
  min-height: 0 !important;
  display: grid !important;
  grid-template-columns: 1fr !important;
  place-items: center !important;
  gap: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  border-radius: inherit !important;
  background: transparent !important;
  color: var(--szpw-text);
  cursor: pointer !important;
  touch-action: manipulation !important;
  -webkit-tap-highlight-color: transparent;
}

#szpw-root[data-drawer-state="minimized"] .szpw-minibar-main:hover {
  background: rgba(255, 99, 0, .08) !important;
}

#szpw-root[data-drawer-state="minimized"] .szpw-minibar-main:active {
  background: rgba(255, 99, 0, .14) !important;
}

#szpw-root[data-drawer-state="minimized"] .szpw-minibar-main:focus-visible {
  outline: 2px solid var(--szpw-accent-2) !important;
  outline-offset: -3px !important;
  box-shadow: none !important;
}

#szpw-root[data-drawer-state="minimized"] .szpw-grip,
#szpw-root[data-drawer-state="minimized"] .szpw-minibar-title,
#szpw-root[data-drawer-state="minimized"] .szpw-counts,
#szpw-root[data-drawer-state="minimized"] .szpw-minibar-controls {
  display: none !important;
}

#szpw-root[data-drawer-state="minimized"] .szpw-launcher-icon {
  width: 30px;
  height: 30px;
  display: grid !important;
  place-items: center;
  border: 1px solid rgba(255, 99, 0, .32);
  border-radius: 10px;
  color: var(--szpw-accent-2);
  background: rgba(255, 99, 0, .10);
  box-shadow: inset 0 1px rgba(255, 255, 255, .035);
  pointer-events: none;
}

#szpw-root[data-drawer-state="minimized"] .szpw-launcher-icon svg {
  width: 18px;
  height: 18px;
  stroke-width: 1.9;
}

#szpw-root[data-drawer-state="minimized"] .szpw-shell.is-minimized:hover {
  border-color: rgba(255, 99, 0, .42) !important;
  box-shadow:
    0 12px 30px rgba(0, 0, 0, .38),
    0 0 0 1px rgba(255, 99, 0, .07),
    inset 0 1px rgba(255, 255, 255, .05) !important;
  transform: translateY(-1px);
}

#szpw-root[data-drawer-state="minimized"] .szpw-shell.is-minimized:active {
  transform: translateY(0) scale(.97);
}

@media (pointer: coarse), (max-width: 620px) {
  #szpw-root[data-drawer-state="minimized"] {
    --szpw-launcher-size: 50px;
    --szpw-launcher-edge: 10px;
  }

  #szpw-root[data-drawer-state="minimized"] .szpw-shell.is-minimized {
    border-radius: 16px !important;
  }

  #szpw-root[data-drawer-state="minimized"] .szpw-launcher-icon {
    width: 32px;
    height: 32px;
  }

  #szpw-root[data-drawer-state="minimized"] .szpw-launcher-icon svg {
    width: 19px;
    height: 19px;
  }
}

/* In the mobile Engineering editor, keep the launcher bottom-left but place
   it just above the editor dock so the two controls never overlap. */
@media (max-width: 620px) {
  body.engineer-mode #szpw-root[data-drawer-state="minimized"] {
    bottom: calc(
      var(--eng-mobile-dock-h, 76px) +
      var(--eng-safe-bottom, env(safe-area-inset-bottom, 0px)) +
      10px
    ) !important;
  }

  body:not(.engineer-mode) .szpw-toast-stack {
    bottom: calc(var(--szpw-launcher-size, 50px) + 22px + env(safe-area-inset-bottom, 0px));
  }
}

/* ======================================================================
   Left-side collection workspace — 20260820-v54
   Expanded Parts & production now enters from the left edge instead of
   behaving like a bottom sheet. The minimized launcher remains bottom-left.
   ====================================================================== */
@keyframes szpw-drawer-enter-left {
  from { transform: translateX(-22px); opacity: .82; }
  to { transform: translateX(0); opacity: 1; }
}

html.szpw-drawer-open #szpw-root:not([data-drawer-state="minimized"]),
body.szpw-drawer-open #szpw-root:not([data-drawer-state="minimized"]) {
  position: fixed !important;
  inset: 0 auto 0 0 !important;
  width: min(1220px, calc(100vw - 48px)) !important;
  max-width: none !important;
  height: 100dvh !important;
  max-height: 100dvh !important;
  padding: 0 !important;
  margin: 0 !important;
  display: block !important;
  pointer-events: none;
}

html.szpw-drawer-open #szpw-root:not([data-drawer-state="minimized"]) .szpw-drawer-backdrop,
body.szpw-drawer-open #szpw-root:not([data-drawer-state="minimized"]) .szpw-drawer-backdrop {
  display: block !important;
  position: fixed !important;
  inset: 0 !important;
  width: 100vw !important;
  height: 100dvh !important;
  opacity: 1 !important;
  visibility: visible !important;
  pointer-events: auto !important;
  background: rgba(3, 8, 7, .48) !important;
  backdrop-filter: blur(3px) !important;
  -webkit-backdrop-filter: blur(3px) !important;
}

html.szpw-drawer-open #szpw-root:not([data-drawer-state="minimized"]) .szpw-shell:not(.is-minimized),
body.szpw-drawer-open #szpw-root:not([data-drawer-state="minimized"]) .szpw-shell:not(.is-minimized) {
  position: relative !important;
  z-index: 2 !important;
  width: 100% !important;
  max-width: none !important;
  height: 100dvh !important;
  max-height: 100dvh !important;
  margin: 0 !important;
  overflow: hidden !important;
  border: 0 !important;
  border-right: 1px solid rgba(177, 201, 191, .22) !important;
  border-radius: 0 22px 22px 0 !important;
  box-shadow:
    28px 0 70px rgba(0, 0, 0, .42),
    1px 0 rgba(255, 255, 255, .025) !important;
  pointer-events: auto !important;
  animation: szpw-drawer-enter-left .2s cubic-bezier(.2,.78,.24,1);
}

html[data-theme="light"].szpw-drawer-open #szpw-root:not([data-drawer-state="minimized"]) .szpw-shell:not(.is-minimized),
html.light-layout.szpw-drawer-open #szpw-root:not([data-drawer-state="minimized"]) .szpw-shell:not(.is-minimized) {
  border-right-color: rgba(26, 47, 38, .18) !important;
  box-shadow: 28px 0 64px rgba(19, 35, 28, .24) !important;
}

@media (max-width: 760px) {
  html.szpw-drawer-open #szpw-root:not([data-drawer-state="minimized"]),
  body.szpw-drawer-open #szpw-root:not([data-drawer-state="minimized"]) {
    width: min(440px, 94vw) !important;
    height: 100dvh !important;
  }

  html.szpw-drawer-open #szpw-root:not([data-drawer-state="minimized"]) .szpw-shell:not(.is-minimized),
  body.szpw-drawer-open #szpw-root:not([data-drawer-state="minimized"]) .szpw-shell:not(.is-minimized) {
    height: 100dvh !important;
    border-radius: 0 18px 18px 0 !important;
  }
}

@media (max-width: 932px) and (max-height: 520px) and (orientation: landscape) {
  html.szpw-drawer-open #szpw-root:not([data-drawer-state="minimized"]),
  body.szpw-drawer-open #szpw-root:not([data-drawer-state="minimized"]) {
    width: min(760px, 82vw) !important;
  }
}

@media (prefers-reduced-motion: reduce) {
  html.szpw-drawer-open #szpw-root:not([data-drawer-state="minimized"]) .szpw-shell:not(.is-minimized),
  body.szpw-drawer-open #szpw-root:not([data-drawer-state="minimized"]) .szpw-shell:not(.is-minimized) {
    animation: none !important;
  }
}


/* Mobile window controls — 20260820-v55
   Phone drawers use a single X control. It minimizes back to the launcher;
   the separate minus button is intentionally removed on mobile. */
@media (max-width: 620px),
       (max-width: 932px) and (max-height: 520px) and (orientation: landscape) {
  .szpw-shell:not(.is-minimized) .szpw-window-minimize {
    display: none !important;
  }

  .szpw-shell:not(.is-minimized) .szpw-window-actions {
    gap: 0 !important;
  }

  .szpw-shell:not(.is-minimized) .szpw-window-close {
    display: grid !important;
  }
}



/* ======================================================================
   Persistent production side launcher — 20260820-v56
   Fresh page loads always start here. The workspace expands only after an
   explicit user action, and close/minimize always returns to this launcher.
   ====================================================================== */
.szpw-launcher-copy,
.szpw-launcher-badge { display: none; }

#szpw-root[data-drawer-state="minimized"] {
  --szpw-launcher-h: 58px;
  top: 50% !important; right: auto !important; bottom: auto !important; left: 0 !important;
  width: 178px !important; min-width: 178px !important; max-width: 178px !important;
  height: var(--szpw-launcher-h) !important; min-height: var(--szpw-launcher-h) !important; max-height: var(--szpw-launcher-h) !important;
  transform: translateY(-50%) !important; z-index: 2147482600 !important;
}
#szpw-root[data-drawer-state="minimized"] .szpw-shell.is-minimized {
  border-radius: 0 18px 18px 0 !important; border-left: 0 !important;
  border-color: rgba(177, 201, 191, .28) !important;
  background: radial-gradient(circle at 0 50%, rgba(255,99,0,.19), transparent 52%), linear-gradient(110deg, rgba(255,99,0,.08), transparent 58%), rgba(12,18,16,.97) !important;
  box-shadow: 12px 10px 36px rgba(0,0,0,.36), 0 0 0 1px rgba(255,255,255,.025) inset !important;
  overflow: visible !important;
}
html[data-theme="light"] #szpw-root[data-drawer-state="minimized"] .szpw-shell.is-minimized,
html.light-layout #szpw-root[data-drawer-state="minimized"] .szpw-shell.is-minimized {
  border-color: rgba(26,47,38,.18) !important;
  background: radial-gradient(circle at 0 50%, rgba(255,99,0,.14), transparent 52%), linear-gradient(110deg, rgba(255,99,0,.07), transparent 58%), rgba(255,255,255,.98) !important;
  box-shadow: 10px 10px 30px rgba(19,35,28,.16) !important;
}
#szpw-root[data-drawer-state="minimized"] .szpw-minibar-main {
  grid-template-columns: 36px minmax(0,1fr) auto !important; justify-items: stretch !important; align-items: center !important;
  gap: 10px !important; padding: 8px 10px 8px 12px !important; border-radius: 0 18px 18px 0 !important;
}
#szpw-root[data-drawer-state="minimized"] .szpw-launcher-icon {
  width: 36px !important; height: 36px !important; border-radius: 12px !important;
  background: linear-gradient(145deg, rgba(255,99,0,.22), rgba(255,99,0,.08)) !important;
  box-shadow: inset 0 1px rgba(255,255,255,.08), 0 5px 14px rgba(255,99,0,.12) !important;
}
#szpw-root[data-drawer-state="minimized"] .szpw-launcher-copy {
  min-width: 0; display: flex !important; flex-direction: column; justify-content: center; gap: 1px; line-height: 1.14; pointer-events: none;
}
#szpw-root[data-drawer-state="minimized"] .szpw-launcher-copy strong {
  overflow: hidden; color: var(--szpw-text); font-size: 12px; font-weight: 800; letter-spacing: -.015em; text-overflow: ellipsis; white-space: nowrap;
}
#szpw-root[data-drawer-state="minimized"] .szpw-launcher-copy small {
  overflow: hidden; color: var(--szpw-muted); font-size: 9px; font-weight: 650; text-overflow: ellipsis; white-space: nowrap;
}
#szpw-root[data-drawer-state="minimized"] .szpw-launcher-badge {
  min-width: 24px; height: 24px; display: inline-grid !important; place-items: center; padding: 0 6px;
  border: 1px solid rgba(255,99,0,.32); border-radius: 999px; color: #ffd8bf; background: rgba(255,99,0,.13);
  font-size: 9px; font-weight: 800; line-height: 1; pointer-events: none;
}
html[data-theme="light"] #szpw-root[data-drawer-state="minimized"] .szpw-launcher-badge,
html.light-layout #szpw-root[data-drawer-state="minimized"] .szpw-launcher-badge { color: #a64200; background: rgba(255,99,0,.09); }
#szpw-root[data-drawer-state="minimized"] .szpw-shell.is-minimized::after {
  content: ""; position: absolute; top: 50%; right: -4px; width: 4px; height: 22px; border-radius: 0 999px 999px 0;
  background: linear-gradient(var(--szpw-accent-2), var(--szpw-accent)); transform: translateY(-50%); box-shadow: 2px 0 12px rgba(255,99,0,.28); pointer-events: none;
}
#szpw-root[data-drawer-state="minimized"] .szpw-shell.is-minimized:hover { transform: translateX(2px) !important; border-color: rgba(255,99,0,.42) !important; }
#szpw-root[data-drawer-state="minimized"] .szpw-shell.is-minimized:active { transform: translateX(1px) scale(.985) !important; }
/* The old chevron beside the part/job counters is intentionally removed. */
.szpw-chevron { display: none !important; }
@media (max-width: 620px), (max-width: 932px) and (max-height: 520px) and (orientation: landscape) {
  #szpw-root[data-drawer-state="minimized"] {
    top: 52% !important; left: 0 !important; bottom: auto !important;
    width: 54px !important; min-width: 54px !important; max-width: 54px !important;
    height: 56px !important; min-height: 56px !important; max-height: 56px !important; transform: translateY(-50%) !important;
  }
  #szpw-root[data-drawer-state="minimized"] .szpw-shell.is-minimized { border-radius: 0 17px 17px 0 !important; }
  #szpw-root[data-drawer-state="minimized"] .szpw-minibar-main { display: grid !important; grid-template-columns: 1fr !important; place-items: center !important; padding: 8px !important; border-radius: 0 17px 17px 0 !important; }
  #szpw-root[data-drawer-state="minimized"] .szpw-launcher-icon { width: 38px !important; height: 38px !important; }
  #szpw-root[data-drawer-state="minimized"] .szpw-launcher-copy,
  #szpw-root[data-drawer-state="minimized"] .szpw-launcher-badge { display: none !important; }
  body.engineer-mode #szpw-root[data-drawer-state="minimized"] { top: 50% !important; bottom: auto !important; }
}

/* ======================================================================
   Bottom-left collection launcher lock — 20260820-v57
   The minimized Collections / Parts & production control is deliberately
   pinned to the maximum bottom-left corner on both desktop and mobile.
   This final override supersedes the older left-edge mid-screen launcher.
   ====================================================================== */
#szpw-root[data-drawer-state="minimized"] {
  --szpw-launcher-corner-size: 54px;
  top: auto !important;
  right: auto !important;
  bottom: 0 !important;
  left: 0 !important;
  width: var(--szpw-launcher-corner-size) !important;
  min-width: var(--szpw-launcher-corner-size) !important;
  max-width: var(--szpw-launcher-corner-size) !important;
  height: var(--szpw-launcher-corner-size) !important;
  min-height: var(--szpw-launcher-corner-size) !important;
  max-height: var(--szpw-launcher-corner-size) !important;
  transform: none !important;
  margin: 0 !important;
  padding: 0 !important;
  z-index: 2147482600 !important;
}

#szpw-root[data-drawer-state="minimized"] .szpw-shell.is-minimized {
  width: 100% !important;
  height: 100% !important;
  min-width: 0 !important;
  min-height: 0 !important;
  border-left: 0 !important;
  border-bottom: 0 !important;
  border-radius: 0 17px 0 0 !important;
  overflow: hidden !important;
  transform: none !important;
  box-shadow: 8px -8px 26px rgba(0,0,0,.34), inset 0 1px rgba(255,255,255,.05) !important;
}

#szpw-root[data-drawer-state="minimized"] .szpw-minibar,
#szpw-root[data-drawer-state="minimized"] .szpw-minibar-main {
  width: 100% !important;
  height: 100% !important;
  min-height: 0 !important;
  border-radius: 0 17px 0 0 !important;
}

#szpw-root[data-drawer-state="minimized"] .szpw-minibar-main {
  display: grid !important;
  grid-template-columns: 1fr !important;
  place-items: center !important;
  gap: 0 !important;
  padding: 7px !important;
}

#szpw-root[data-drawer-state="minimized"] .szpw-launcher-icon {
  width: 38px !important;
  height: 38px !important;
  display: grid !important;
  place-items: center !important;
  border-radius: 12px !important;
}
#szpw-root[data-drawer-state="minimized"] .szpw-launcher-icon svg {
  width: 20px !important;
  height: 20px !important;
}
#szpw-root[data-drawer-state="minimized"] .szpw-launcher-copy,
#szpw-root[data-drawer-state="minimized"] .szpw-launcher-badge,
#szpw-root[data-drawer-state="minimized"] .szpw-minibar-title,
#szpw-root[data-drawer-state="minimized"] .szpw-counts,
#szpw-root[data-drawer-state="minimized"] .szpw-minibar-controls,
#szpw-root[data-drawer-state="minimized"] .szpw-grip,
#szpw-root[data-drawer-state="minimized"] .szpw-shell.is-minimized::after {
  display: none !important;
}
#szpw-root[data-drawer-state="minimized"] .szpw-shell.is-minimized:hover {
  transform: translateY(-1px) !important;
}
#szpw-root[data-drawer-state="minimized"] .szpw-shell.is-minimized:active {
  transform: scale(.97) !important;
  transform-origin: left bottom !important;
}

@media (max-width: 620px),
       (max-width: 932px) and (max-height: 520px) and (orientation: landscape) {
  #szpw-root[data-drawer-state="minimized"],
  body.engineer-mode #szpw-root[data-drawer-state="minimized"] {
    --szpw-launcher-corner-size: 56px;
    top: auto !important;
    right: auto !important;
    bottom: 0 !important;
    left: 0 !important;
    transform: none !important;
  }
  #szpw-root[data-drawer-state="minimized"] .szpw-shell.is-minimized,
  #szpw-root[data-drawer-state="minimized"] .szpw-minibar,
  #szpw-root[data-drawer-state="minimized"] .szpw-minibar-main {
    border-radius: 0 18px 0 0 !important;
  }
  #szpw-root[data-drawer-state="minimized"] .szpw-launcher-icon {
    width: 40px !important;
    height: 40px !important;
  }
}
