
:root{
  --bg:#0a0a0a;
  --panel:#111111;
  --border:#1f1f1f;
  --text:#e5e5e5;
  --muted:#9a9a9a;
  --accent:#bdbdbd;
  --accent-2:#d4d4d4;
  --chip:#151515;
  --warn:#f59e0b;
  --shadow:0 0 0 1px var(--border);
  --logo-accent-fg:#011121;
  --logo-accent-text-shadow:0 2px 6px rgba(3,7,18,0.45),0 0 14px rgba(255,255,255,0.6);
}

.sr-only{
  position:absolute;
  width:1px;
  height:1px;
  padding:0;
  margin:-1px;
  overflow:hidden;
  clip:rect(0 0 0 0);
  white-space:nowrap;
  border:0;
}

.is-hidden{display:none!important}


body.is-loading header,
body.is-loading main,
body.is-loading footer{visibility:hidden}

.splash-screen{position:fixed;inset:0;display:flex;align-items:center;justify-content:center;background:var(--bg);color:var(--text);z-index:200;opacity:1;transition:opacity .35s ease,visibility .35s ease}
.splash-screen--hidden{opacity:0;visibility:hidden;pointer-events:none}
.splash-screen__content{display:flex;flex-direction:column;align-items:center;gap:18px;text-align:center}
.splash-screen__logo{display:flex;align-items:center;justify-content:center}
.brand-logo{display:inline-flex;align-items:center;gap:14px;margin:0;font-weight:700;letter-spacing:.04em}
/* Base accent styling kept aligned with main and extended with LED embellishments */
.brand-logo__accent{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  padding:10px 16px;
  border-radius:14px;
  background:linear-gradient(135deg,var(--accent) 0%,var(--accent-2) 100%);
  color:var(--logo-accent-fg);
  font-size:0.9em;
  letter-spacing:.24em;
  box-shadow:0 6px 18px rgba(9,9,9,0.35);
  text-transform:uppercase;
  position:relative;
  overflow:hidden;
  isolation:isolate;
  text-shadow:var(--logo-accent-text-shadow);
}
.brand-logo__accent::before{
  content:"";
  position:absolute;
  inset:2px;
  border-radius:inherit;
  background:radial-gradient(circle at 12% 20%,rgba(255,255,255,0.85) 0,rgba(255,255,255,0) 52%),radial-gradient(circle at 78% 28%,rgba(255,255,255,0.6) 0,rgba(255,255,255,0) 58%),radial-gradient(circle at 42% 82%,rgba(255,255,255,0.45) 0,rgba(255,255,255,0) 55%);
  opacity:.6;
  mix-blend-mode:screen;
  pointer-events:none;
}
.brand-logo__accent::after{
  content:"";
  position:absolute;
  inset:-18%;
  border-radius:inherit;
  background:radial-gradient(circle,rgba(255,255,255,0.18) 0,rgba(255,255,255,0) 62%),repeating-radial-gradient(circle at 0 0,rgba(255,255,255,0.45),rgba(255,255,255,0.45) 1.5px,transparent 1.5px,transparent 6px);
  opacity:.35;
  filter:blur(6px);
  mix-blend-mode:screen;
  pointer-events:none;
}
.brand-logo__text{font-size:1.1em;color:var(--text);text-shadow:0 8px 20px rgba(0,0,0,0.35)}
.brand-logo__badge{font-size:0.55em;letter-spacing:.16em;padding:6px 18px;border-radius:999px;background:var(--chip);border:1px solid var(--border);color:var(--muted);text-transform:uppercase}
.brand-logo--splash{font-size:36px;gap:18px}
.brand-logo--splash .brand-logo__accent{font-size:0.85em;padding:12px 22px;letter-spacing:.28em}
.brand-logo--splash .brand-logo__text{font-size:0.95em;letter-spacing:.12em}
.brand-logo--splash .brand-logo__badge{font-size:0.5em;padding:8px 22px}
.splash-screen__tagline{font-size:12px;color:var(--muted);margin:0}

.password-gate{position:fixed;inset:0;display:flex;align-items:center;justify-content:center;background:rgba(9,13,18,0.88);z-index:240;opacity:0;visibility:hidden;pointer-events:none;transition:opacity .3s ease,visibility .3s ease}
.password-gate--visible{opacity:1;visibility:visible;pointer-events:auto}
.password-gate__panel{background:var(--panel);border:1px solid var(--border);border-radius:18px;padding:28px;box-shadow:0 22px 48px rgba(2,6,23,0.65);width:min(90%,360px);display:flex;flex-direction:column;gap:16px;text-align:left}
.password-gate__title{margin:0;font-size:16px;letter-spacing:.08em;text-transform:uppercase;color:var(--accent-2)}
.password-gate__description{margin:0;font-size:12px;color:var(--muted);line-height:1.5}
.password-gate__form{display:flex;flex-direction:column;gap:12px}
.password-gate__field{display:flex;flex-direction:column;gap:6px;font-size:11px;color:var(--muted)}
.password-gate__field input{padding:10px 12px;border-radius:10px;font-size:13px;background:var(--bg);border:1px solid var(--border);color:var(--text)}
.password-gate__field input:focus{outline:2px solid var(--accent-2);outline-offset:2px}
.password-gate__error{min-height:16px;margin:0;font-size:11px;color:#ef4444}
.password-gate__submit{align-self:flex-start;padding:10px 20px;font-size:12px}

body.password-required{overflow:hidden}

body.theme-classic{
  --bg:#0b0f14;
  --panel:#0f141c;
  --border:#1b2430;
  --text:#e6edf3;
  --muted:#9ca3af;
  --accent:#f97316;
  --accent-2:#fb923c;
  --chip:#161d27;
  --warn:#f59e0b;
  --shadow:0 0 0 1px var(--border);
}

/* Calculator theme: high contrast slate with warm accents */
body.theme-calculator{
  --bg:#090d12;
  --panel:#111821;
  --border:#1f2a38;
  --text:#f1f5f9;
  --muted:#a5adbb;
  --accent:#f97316;
  --accent-2:#fbbf24;
  --chip:#162030;
}

body.modal-open{overflow:hidden}

*{box-sizing:border-box}
html,body{height:100%}
body{margin:0;font-family:ui-sans-serif,system-ui,-apple-system,Segoe UI,Roboto,Helvetica,Arial,sans-serif;color:var(--text);background:var(--bg);overflow-x:hidden}
.visually-hidden{position:absolute!important;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}

header{display:flex;align-items:center;justify-content:space-between;padding:8px 12px;background:var(--panel);border-bottom:1px solid var(--border)}
h1{margin:0;font-weight:700;font-size:18px}
.brand-logo--header{font-size:18px;gap:10px}
.brand-logo--header .brand-logo__accent{font-size:0.95em;padding:6px 14px;border-radius:10px;letter-spacing:.2em}
.brand-logo--header .brand-logo__text{font-size:0.9em;letter-spacing:.08em}
.brand-logo--header .brand-logo__badge{font-size:0.55em;padding:4px 12px}

header .actions{display:flex;align-items:center;gap:6px;flex-wrap:wrap;justify-content:flex-end}
header .actions select, header .actions .compact-toggle{margin-right:6px;font-size:12px;color:var(--muted)}
header .actions button{white-space:nowrap}

.tutorial-bubble{
  position:absolute;
  max-width:280px;
  background:var(--panel);
  border:1px solid var(--border);
  border-radius:12px;
  padding:16px;
  box-shadow:0 20px 48px rgba(3,7,18,0.42);
  z-index:4000;
  color:var(--text);
  display:flex;
  flex-direction:column;
  gap:10px;
}
.tutorial-bubble__progress{font-size:11px;letter-spacing:.08em;text-transform:uppercase;color:var(--muted)}
.tutorial-bubble__title{margin:0;font-size:16px;font-weight:600;color:var(--text)}
.tutorial-bubble__body{margin:0;font-size:13px;line-height:1.5;color:var(--muted)}
.tutorial-bubble__note{margin:0;font-size:12px;color:var(--muted);opacity:0.9}
.tutorial-bubble__controls{display:flex;justify-content:flex-end}
.tutorial-bubble__btn{background:none;border:1px solid var(--border);border-radius:8px;color:var(--muted);font-size:12px;padding:6px 10px;cursor:pointer;transition:color .2s ease,border-color .2s ease}
.tutorial-bubble__btn:hover,.tutorial-bubble__btn:focus-visible{color:var(--text);border-color:var(--accent)}
.tutorial-highlight{outline:2px solid var(--accent);outline-offset:3px;border-radius:8px;box-shadow:0 0 0 6px rgba(249,115,22,0.22)}

.export-menu,
.preset-menu{position:relative}
.export-menu>button,
.preset-menu>button{padding:6px 10px}
.export-menu__list,
.preset-menu__list{position:absolute;right:0;top:calc(100% + 4px);display:none;flex-direction:column;min-width:160px;background:var(--panel);border:1px solid var(--border);border-radius:10px;padding:6px;box-shadow:0 8px 20px rgba(0,0,0,0.45);z-index:30}
.export-menu__list.open,
.preset-menu__list.open{display:flex}
.export-menu__list button,
.preset-menu__list button{width:100%;justify-content:flex-start;text-align:left;background:var(--bg);border:1px solid transparent;padding:8px 10px;font-size:12px;color:var(--text)}
.export-menu__list button:hover,
.preset-menu__list button:hover{background:var(--panel);border-color:var(--border)}

main{display:grid;grid-template-columns:minmax(300px,360px) minmax(0,1fr);gap:12px;padding:12px;min-height:calc(100vh - 48px);align-items:start}
aside#sidebar{padding:0 12px 24px 0;overflow:auto;border-right:1px solid var(--border);display:flex;flex-direction:column;gap:12px}
aside#sidebar::-webkit-scrollbar{width:6px}
aside#sidebar::-webkit-scrollbar-thumb{background:var(--border);border-radius:999px}
aside#sidebar::-webkit-scrollbar-track{background:transparent}
.panel{background:var(--panel);border:1px solid var(--border);border-radius:10px;padding:8px;box-shadow:var(--shadow)}
section{margin:0;background:var(--panel);border:1px solid var(--border);border-radius:10px;padding:0;box-shadow:var(--shadow)}
section.collapsible details{padding:6px 8px;display:flex;flex-direction:column;gap:8px}
section.collapsible details:not([open]){padding:3px 8px;gap:4px}
section.collapsible details summary{padding:2px 0;display:flex;align-items:center;justify-content:flex-start;gap:6px;cursor:pointer;list-style:none;font-size:11px;font-weight:600;color:var(--accent);margin:0;line-height:1.2}
section.collapsible details:not([open]) summary{padding:1px 0;line-height:1.05}
section details summary::-webkit-details-marker{display:none}
section details summary span{pointer-events:none}
section details summary button.summary-action{pointer-events:auto}
section details summary::after{content:'\25bc';font-size:10px;color:var(--muted);transition:transform .2s ease;margin-left:auto}
section details[open] summary::after{transform:rotate(180deg)}
section .collapsible-body{display:flex;flex-direction:column;gap:8px}

.summary-action{font-size:10px;padding:4px 12px;border-radius:999px;margin-left:6px;width:auto;flex:0 0 auto;white-space:nowrap}
.summary-action.secondary{line-height:1.2}

.panel--wall-switcher{display:flex;flex-direction:column;gap:6px;font-size:11px;color:var(--muted)}
.panel--wall-switcher .wall-switcher__field{display:flex;flex-direction:column;gap:2px;color:var(--muted)}
.panel--wall-switcher .wall-switcher__field span{font-weight:600;color:var(--accent)}
.panel--wall-switcher select,
.panel--wall-switcher input{width:100%;font-size:11px;padding:4px 6px;border-radius:6px;border:1px solid var(--border);background:var(--bg);color:var(--text)}
.panel--wall-switcher .wall-switcher__actions{display:flex;justify-content:flex-end;margin-top:4px}
.panel--wall-switcher .wall-switcher__actions .secondary{font-size:11px;padding:4px 12px}

#tileSpecsPanel>details,
#processorSpecsPanel>details,
#layoutPanel>details,
#tileToolsPanel>details,
#chainPanel>details{padding:4px 6px;gap:6px}
#tileSpecsPanel>details:not([open]),
#processorSpecsPanel>details:not([open]),
#layoutPanel>details:not([open]),
#tileToolsPanel>details:not([open]),
#chainPanel>details:not([open]){padding:2px 6px;gap:3px}
#tileSpecsPanel>details summary,
#processorSpecsPanel>details summary,
#layoutPanel>details summary,
#tileToolsPanel>details summary,
#chainPanel>details summary{padding:1px 0;line-height:1.1}
#tileSpecsPanel .collapsible-body,
#processorSpecsPanel .collapsible-body,
#layoutPanel .collapsible-body,
#tileToolsPanel .collapsible-body,
#chainPanel .collapsible-body{gap:6px}

.spec-section details{gap:16px}
.spec-row{display:flex;flex-wrap:wrap;gap:8px;align-items:flex-end}
.spec-field{display:flex;flex-direction:column;gap:4px;font-size:11px;color:var(--muted);flex:1 1 160px}
.spec-field--wide{flex:2 1 200px}
.spec-row button{width:auto;flex:0 0 auto;align-self:flex-end}
.spec-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(160px,1fr));gap:8px}
.spec-grid--advanced{grid-template-columns:repeat(auto-fit,minmax(160px,1fr))}
.spec-readout{display:flex;flex-direction:column;gap:4px;padding:8px;border:1px solid var(--border);border-radius:8px;background:var(--panel);color:var(--text);min-height:52px}
.spec-readout__item{display:flex;justify-content:space-between;gap:12px;font-size:11px}
.spec-readout__item .label{font-size:10px;text-transform:uppercase;letter-spacing:.04em;color:var(--muted)}
.spec-readout__item .value{font-weight:600;color:var(--text)}
.spec-readout__line{font-size:11px;color:var(--muted)}
.spec-readout__line strong{color:var(--text)}
.spec-readout__block{padding:6px 0;border-top:1px solid var(--border)}
.spec-readout__block:first-child{border-top:0;padding-top:0}
.spec-readout__block strong{color:var(--text);font-weight:600}
.spec-readout__block--active strong{color:var(--accent-2)}
.spec-advanced{background:var(--bg);border:1px dashed var(--border);border-radius:8px;padding:8px}
.spec-advanced summary{font-size:11px;font-weight:600;color:var(--muted);display:flex;align-items:center;justify-content:space-between}
.spec-advanced summary::after{content:'\25bc';font-size:10px;color:var(--muted);transition:transform .2s ease}
.spec-advanced[open] summary::after{transform:rotate(180deg)}
.spec-advanced > *:not(summary){margin-top:8px}
.spec-actions{display:flex;flex-wrap:wrap;gap:8px;align-items:center}
.spec-actions button{width:auto}
.frame-rate-picker{display:flex;align-items:center;gap:6px}
.frame-rate-picker select{flex:1 1 auto;min-width:0}
.frame-rate-picker__custom{flex:0 0 90px;padding:6px 8px;border-radius:8px;border:1px solid var(--border);background:var(--bg);color:var(--text);font-size:12px}

.grid3{display:grid;grid-template-columns:repeat(3,1fr);gap:6px;align-items:center}
.row{display:flex;gap:6px;align-items:center;margin-top:6px}
.preset-status{flex:1 1 200px;font-size:11px;color:var(--muted);min-height:14px}
.preset-status.success{color:var(--accent-2)}
.preset-status.error{color:#f87171}

.controls-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(220px,1fr));gap:10px}
.control-card{background:var(--bg);border:1px solid var(--border);border-radius:10px;padding:8px;display:flex;flex-direction:column;gap:8px}
.control-card-header{display:flex;justify-content:space-between;align-items:center;gap:8px}
.control-card-header h3{margin:0;font-size:12px;color:var(--accent-2);text-transform:uppercase;letter-spacing:.06em}
.control-metric{font-size:11px;color:var(--accent-2);font-weight:600;background:var(--chip);border-radius:999px;padding:4px 8px;border:1px solid var(--border)}
.control-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(120px,1fr));gap:8px}
.control-grid--builder{grid-template-columns:repeat(auto-fit,minmax(140px,1fr))}
.quick-target-builder{margin-top:10px;padding-top:10px;border-top:1px solid var(--border);display:flex;flex-direction:column;gap:8px}
.quick-target-builder__header{display:flex;align-items:center;justify-content:space-between;gap:8px;flex-wrap:wrap}
.quick-target-builder__header h4{margin:0;font-size:11px;text-transform:uppercase;letter-spacing:.06em;color:var(--accent-2)}
.quick-target-builder__header button{width:auto}
.quick-target-builder__hint{margin:0;font-size:11px;color:var(--muted);line-height:1.45}
.quick-target-builder__result:empty{display:none}
.quick-target-result{display:flex;flex-direction:column;gap:4px;padding:8px;border-radius:8px;border:1px solid var(--border);background:rgba(15,23,30,.55);font-size:11px;line-height:1.45}
.quick-target-result strong{color:var(--text);font-size:11px}
.quick-target-result span{color:var(--muted)}
.quick-target-result--success{border-color:rgba(56,189,248,.25);background:rgba(14,165,233,.08)}
.quick-target-result--error{border-color:rgba(248,113,113,.28);background:rgba(239,68,68,.08);color:var(--text)}
.quick-target-options{display:flex;flex-direction:column;gap:6px;margin-top:6px;padding-top:6px;border-top:1px solid rgba(148,163,184,.2)}
.quick-target-options__header{font-size:10px;font-weight:700;letter-spacing:.08em;text-transform:uppercase;color:var(--accent-2)}
.quick-target-options__list{display:flex;flex-direction:column;gap:6px}
.quick-target-option{display:flex;gap:8px;justify-content:space-between;align-items:flex-start;padding:8px;border-radius:8px;border:1px solid rgba(148,163,184,.22);background:rgba(15,23,30,.45)}
.quick-target-option__body{display:flex;flex-direction:column;gap:3px;min-width:0}
.quick-target-option__meta{font-size:10px;color:var(--accent-2)}
.quick-target-option__apply{width:auto;flex:0 0 auto;align-self:center}
.quick-target-compare__grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(220px,1fr));gap:8px}
.quick-target-compare__card{display:flex;flex-direction:column;gap:8px;padding:10px;border-radius:10px;border:1px solid rgba(148,163,184,.22);background:rgba(15,23,30,.45);min-width:0}
.quick-target-compare__card--featured{border-color:rgba(56,189,248,.32);background:rgba(14,165,233,.1);box-shadow:0 0 0 1px rgba(56,189,248,.08)}
.quick-target-compare__header{display:flex;justify-content:space-between;gap:8px;align-items:flex-start}
.quick-target-compare__header-copy{display:flex;flex-direction:column;gap:3px;min-width:0}
.quick-target-compare__meta{font-size:10px;color:var(--accent-2)}
.quick-target-compare__badge{display:inline-flex;align-items:center;justify-content:center;padding:3px 7px;border-radius:999px;background:rgba(148,163,184,.16);color:var(--accent-2);font-size:10px;font-weight:700;letter-spacing:.05em;text-transform:uppercase;white-space:nowrap}
.quick-target-compare__reason{margin:0;color:var(--muted);font-size:11px;line-height:1.45}
.quick-target-compare__score-row{display:flex;justify-content:space-between;gap:8px;align-items:center;flex-wrap:wrap}
.quick-target-compare__score-block{display:flex;flex-direction:column;gap:2px}
.quick-target-compare__score-label{font-size:10px;color:var(--accent-2);text-transform:uppercase;letter-spacing:.06em}
.quick-target-compare__score-value{font-size:20px;line-height:1;color:var(--text)}
.quick-target-compare__metrics{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:6px}
.quick-target-compare__metric{display:flex;flex-direction:column;gap:2px;padding:7px 8px;border-radius:8px;background:rgba(2,6,23,.24);border:1px solid rgba(148,163,184,.12)}
.quick-target-compare__metric-top{display:flex;align-items:center;justify-content:space-between;gap:8px;font-size:11px;color:var(--text)}
.quick-target-compare__metric-top strong{font-size:12px;color:var(--accent-2)}
.quick-target-compare__metric-detail{font-size:10px;line-height:1.4;color:var(--muted)}

.quick-target-distribution__grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(230px,1fr));gap:8px}
.quick-target-distribution__card{display:flex;flex-direction:column;gap:8px;padding:10px;border-radius:10px;border:1px solid rgba(148,163,184,.22);background:rgba(15,23,30,.45);min-width:0}
.quick-target-distribution__card--current{border-color:rgba(56,189,248,.32);background:rgba(14,165,233,.08);box-shadow:0 0 0 1px rgba(56,189,248,.08)}
.quick-target-distribution__header{display:flex;justify-content:space-between;gap:8px;align-items:flex-start}
.quick-target-distribution__header-copy{display:flex;flex-direction:column;gap:3px;min-width:0}
.quick-target-distribution__meta{font-size:10px;color:var(--accent-2)}
.quick-target-distribution__badge{display:inline-flex;align-items:center;justify-content:center;padding:3px 7px;border-radius:999px;background:rgba(148,163,184,.16);color:var(--accent-2);font-size:10px;font-weight:700;letter-spacing:.05em;text-transform:uppercase;white-space:nowrap}
.quick-target-distribution__status{margin:0;font-size:11px;line-height:1.45;color:var(--text)}
.quick-target-distribution__note{margin:0;font-size:10px;line-height:1.45;color:var(--muted)}
.quick-target-distribution__score-row{display:flex;gap:8px;flex-wrap:wrap}
.quick-target-distribution__score-block{display:flex;flex-direction:column;gap:2px;min-width:90px;padding:7px 8px;border-radius:8px;background:rgba(2,6,23,.24);border:1px solid rgba(148,163,184,.12)}
.quick-target-distribution__score-block span{font-size:10px;color:var(--accent-2);text-transform:uppercase;letter-spacing:.06em}
.quick-target-distribution__score-block strong{font-size:18px;line-height:1;color:var(--text)}
.quick-target-distribution__layout{font-size:10px;line-height:1.45;color:var(--accent-2)}

.control-card--walls{gap:10px}
.control-card-dropdown{background:var(--panel);border:1px solid var(--border);border-radius:10px;overflow:hidden;display:flex;flex-direction:column}
.control-card-dropdown+.control-card-dropdown{margin-top:8px}
.control-card-dropdown summary{list-style:none;display:flex;align-items:center;justify-content:space-between;gap:8px;padding:10px 12px;font-size:12px;color:var(--accent-2);font-weight:600;text-transform:uppercase;letter-spacing:.06em;cursor:pointer}
.control-card-dropdown summary::-webkit-details-marker{display:none}
.control-card-dropdown summary:focus-visible{outline:2px solid var(--accent-2);outline-offset:2px;border-radius:8px}
.control-card-dropdown[open] summary{border-bottom:1px solid var(--border)}
.control-card-dropdown__body{display:flex;flex-direction:column;gap:8px;padding:12px}
.control-card-dropdown__actions{display:flex;justify-content:flex-end;margin-bottom:4px}
.control-card-dropdown__actions button{width:auto}
.control-grid--rigging{display:grid;grid-template-columns:repeat(auto-fit,minmax(160px,1fr));gap:8px}
.rigging-editor{display:flex;flex-direction:column;gap:8px;padding:8px;border:1px solid rgba(148,163,184,.3);border-radius:8px;background:rgba(148,163,184,.08)}
.rigging-editor__row{display:flex;flex-wrap:wrap;gap:8px;align-items:center}
.rigging-editor__row select{flex:1 1 180px}
.rigging-editor__buttons{display:flex;gap:8px;flex-wrap:wrap}
.rigging-editor__status{font-size:12px;color:#64748b}
.rigging-editor__status--active{color:#0ea5e9}
.rigging-editor__list{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:6px}
.rigging-editor__item{display:flex;flex-wrap:wrap;gap:8px;align-items:center;justify-content:space-between;background:rgba(15,23,42,.08);border-radius:6px;padding:6px 10px}
.rigging-editor__item-label{font-weight:500;color:#1e293b}
.rigging-editor__item-count{font-size:12px;color:#475569}
.rigging-editor__reset{margin-left:auto}
.rigging-editor__empty{font-size:12px;color:#94a3b8}
.control-field.control-field--wide{grid-column:1 / -1}
.wall-mount-toggle{display:inline-flex;gap:4px;flex-wrap:wrap}
.wall-mount-toggle__btn{padding:3px 8px;border-radius:999px;text-transform:uppercase;font-size:9px;letter-spacing:.08em;background:var(--chip);color:var(--accent-2);border:1px solid var(--border);transition:background .15s ease,color .15s ease}
.wall-mount-toggle__btn.is-active{background:var(--accent-2);color:#04111d;border-color:var(--accent-2);box-shadow:0 0 0 1px rgba(4,17,29,0.35)}
.wall-mount-toggle__btn:focus-visible{outline:2px solid var(--accent-2);outline-offset:2px}
.control-card--walls textarea{min-height:72px;resize:vertical}
.test-pattern-control{display:flex;flex-wrap:wrap;gap:6px;align-items:center}
.test-pattern-select{flex:0 0 auto;position:relative}
.test-pattern-select select{background:#111827;border:1px solid #1f2937;border-radius:4px;color:#e2e8f0;font:500 13px "Inter",system-ui,sans-serif;padding:6px 28px 6px 12px;appearance:none;min-width:180px;box-shadow:0 1px 2px rgba(15,23,42,0.35)}
.test-pattern-select::after{content:"";position:absolute;pointer-events:none;top:50%;right:12px;width:0;height:0;border-left:5px solid transparent;border-right:5px solid transparent;border-top:6px solid #94a3b8;transform:translateY(-50%)}
.test-pattern-control .secondary{flex:0 0 auto}
.test-pattern-control .link{flex:0 0 auto}
.test-pattern-toggle{display:inline-flex;align-items:center;gap:4px;font-size:11px;color:var(--muted)}
.test-pattern-toggle input{margin:0}
.test-pattern-border{display:inline-flex;align-items:center;gap:4px;font-size:11px;color:var(--muted)}
.test-pattern-border input{margin:0}
.test-pattern-border-color{display:inline-flex;align-items:center;gap:6px;font-size:11px;color:var(--muted)}
.test-pattern-border-color input{margin:0;padding:0;width:36px;height:26px;border:1px solid var(--border);border-radius:4px;background:#111827;cursor:pointer}
.test-pattern-border-color input::-webkit-color-swatch{border:none;border-radius:2px}
.test-pattern-border-color input::-webkit-color-swatch-wrapper{padding:0;border-radius:2px}
.test-pattern-border-color input::-moz-color-swatch{border:none;border-radius:2px}
.test-pattern-status{flex:1 1 100%;font-size:10px;color:var(--muted)}
.test-pattern-status--empty{opacity:0.7}
.test-pattern-tile-border{display:inline-flex;align-items:center;gap:4px;font-size:11px;color:var(--muted)}
.test-pattern-tile-border input{margin:0}
.control-grid--sections{display:grid;grid-template-columns:minmax(0,1fr);gap:8px}
.section-actions{display:flex;gap:8px;align-items:center;flex-wrap:wrap}
.section-actions button{flex:1 1 140px;min-width:110px;height:36px}
.section-actions #sectionColor{padding:0;height:36px;width:42px;border-radius:8px;cursor:pointer;display:block}
.section-actions #sectionColor::-webkit-color-swatch{border:none;border-radius:6px}
.section-actions #sectionColor::-webkit-color-swatch-wrapper{padding:0;border-radius:6px}
.section-actions #sectionColor::-moz-color-swatch{border:none;border-radius:6px}
.section-legend-dropdown{border:1px solid var(--border);border-radius:8px;background:var(--bg);padding:0}
.section-legend-dropdown summary{list-style:none;padding:4px 8px;display:flex;align-items:center;justify-content:space-between;font-size:10px;font-weight:600;color:var(--accent);text-transform:uppercase;letter-spacing:.06em;cursor:pointer}
.section-legend-dropdown summary::-webkit-details-marker{display:none}
.section-legend-dropdown summary::after{content:'\25bc';font-size:10px;color:var(--muted);transition:transform .2s ease}
.section-legend-dropdown:not([open]) summary::after{transform:rotate(-90deg)}
.section-legend-dropdown__body{padding:6px 8px 8px;display:flex}
.section-legend-dropdown:not([open]){padding-bottom:0}
.control-field{display:flex;flex-direction:column;gap:4px;font-size:11px;color:var(--muted)}
.control-field.control-field--inline{gap:6px}
.control-card select{width:100%}
.control-buttons{display:flex;flex-wrap:wrap;gap:6px}
.control-buttons button{flex:1 1 100px}
.zoom-buttons{display:flex;gap:6px;margin:8px 0 0 0;flex-wrap:wrap}
.zoom-buttons button{flex:1 1 90px}
.placement-mode{display:flex;flex-wrap:wrap;gap:6px}
.placement-mode__btn{flex:1 1 120px;padding:4px 9px;border-radius:999px;text-transform:uppercase;font-size:9px;letter-spacing:.08em;background:var(--chip);color:var(--accent-2);border:1px solid var(--border);transition:background .15s ease,color .15s ease}
.placement-mode__btn.is-active{background:var(--accent-2);color:#04111d;border-color:var(--accent-2);box-shadow:0 0 0 1px rgba(4,17,29,0.35)}
.placement-mode__btn:disabled{opacity:0.5;cursor:not-allowed}

.preset-modal{position:fixed;inset:0;display:none;align-items:center;justify-content:center;padding:24px;z-index:160}
.preset-modal::before{content:"";position:absolute;inset:0;background:rgba(4,8,12,0.78);backdrop-filter:blur(3px)}
.preset-modal__backdrop{position:absolute;inset:0}
.preset-modal--open{display:flex}
.preset-modal__dialog{position:relative;background:var(--panel);border:1px solid var(--border);border-radius:16px;box-shadow:0 24px 80px rgba(0,0,0,0.65);width:min(1040px,calc(100% - 32px));max-height:calc(100vh - 48px);display:flex;flex-direction:column;overflow:hidden}
.preset-modal__header{display:flex;align-items:center;justify-content:space-between;padding:18px 22px;border-bottom:1px solid var(--border)}
.preset-modal__header h2{margin:0;font-size:18px;letter-spacing:.04em;text-transform:uppercase;color:var(--accent-2)}
.preset-modal__close{background:var(--chip);border:1px solid var(--border);color:var(--muted);font-size:20px;line-height:1;width:34px;height:34px;border-radius:999px;display:flex;align-items:center;justify-content:center;cursor:pointer;transition:background .15s ease,color .15s ease}
.preset-modal__close:hover,.preset-modal__close:focus{background:var(--accent-2);color:#04111d;outline:none}
.preset-modal__body{padding:20px 24px;overflow:auto;display:flex;flex-direction:column;gap:18px}
.preset-modal__form{display:flex;flex-direction:column;gap:16px}
.preset-modal__form[hidden]{display:none!important}
.preset-modal__grid{display:grid;gap:10px}
.preset-modal__grid--overview{grid-template-columns:repeat(auto-fit,minmax(200px,1fr))}
.preset-modal__grid--variant{grid-template-columns:repeat(auto-fit,minmax(180px,1fr))}
.preset-modal__variants{display:flex;flex-direction:column;gap:16px}
.preset-modal__variant{padding:16px;border:1px solid var(--border);border-radius:14px;background:var(--bg);display:flex;flex-direction:column;gap:14px;box-shadow:var(--shadow)}
.preset-modal__variant-header{display:flex;align-items:center;justify-content:space-between}
.preset-modal__variant-header h4{margin:0;font-size:13px;letter-spacing:.06em;text-transform:uppercase;color:var(--accent)}
.preset-modal__notes textarea{min-height:72px;resize:vertical;background:var(--bg);color:var(--text);border:1px solid var(--border);border-radius:10px;padding:10px;font-size:12px}
.preset-modal__section{display:flex;flex-direction:column;gap:12px;padding:16px;border:1px solid var(--border);border-radius:14px;background:var(--bg);box-shadow:var(--shadow)}
.preset-modal__section-header{display:flex;align-items:center;justify-content:space-between;gap:12px}
.preset-modal__section-header h3{margin:0;font-size:13px;letter-spacing:.06em;text-transform:uppercase;color:var(--accent)}
.preset-modal__stack{display:flex;flex-direction:column;gap:12px}
.preset-modal__card{border:1px solid var(--border);border-radius:12px;padding:14px;background:var(--panel);display:flex;flex-direction:column;gap:10px}
.preset-modal__card-header{display:flex;align-items:center;justify-content:space-between;gap:10px}
.preset-modal__card-header h4{margin:0;font-size:12px;text-transform:uppercase;letter-spacing:.05em;color:var(--accent-2)}
.preset-modal__card-actions{display:flex;align-items:center;gap:10px}
.preset-modal__remove{background:var(--chip);border:1px solid var(--border);color:var(--muted);font-size:11px;padding:4px 10px;border-radius:8px;cursor:pointer;transition:background .15s ease,color .15s ease}
.preset-modal__remove:hover,.preset-modal__remove:focus{background:#ef4444;color:#04111d;border-color:#ef4444;outline:none}
.preset-modal__radio{display:inline-flex;align-items:center;gap:6px;font-size:11px;color:var(--muted)}
.preset-modal__radio input{accent-color:var(--accent-2)}
.preset-modal__footer{display:flex;justify-content:flex-end;gap:10px;padding:16px 22px;border-top:1px solid var(--border);background:var(--panel)}
.preset-modal__type{max-width:220px}
.preset-modal__form .spec-field input,
.preset-modal__form .spec-field select,
.preset-modal__form .spec-field textarea{background:var(--bg);border:1px solid var(--border);border-radius:10px;color:var(--text);padding:8px 10px;font-size:12px}
.preset-modal__form .spec-field textarea{resize:vertical}
.preset-modal__form .spec-field select{padding-right:28px}
.preset-modal__grid--compact{grid-template-columns:repeat(auto-fit,minmax(160px,1fr))}
.preset-modal__hint{font-size:11px;color:var(--muted);margin:0}

.preset-menu>button[aria-haspopup="dialog"]{position:relative}
.placement-mode.is-disabled{opacity:0.7}
.orientation-toggle{display:inline-flex;gap:4px}
.orientation-toggle__btn{padding:3px 8px;border-radius:999px;text-transform:uppercase;font-size:9px;letter-spacing:.08em;background:var(--chip);color:var(--accent-2);border:1px solid var(--border);transition:background .15s ease,color .15s ease}
.orientation-toggle__btn.is-active{background:var(--accent-2);color:#04111d;border-color:var(--accent-2);box-shadow:0 0 0 1px rgba(4,17,29,0.35)}
.orientation-toggle__btn:disabled{opacity:0.5;cursor:not-allowed}
.orientation-toggle.is-disabled{opacity:0.6}
button.primary{background:var(--accent-2);color:#04111d;border-color:var(--accent-2)}
button.primary:hover{background:var(--accent);color:#04111d}
button.secondary{background:var(--chip);color:var(--accent-2);border-color:var(--border)}
button.secondary:hover{background:var(--panel);color:var(--accent)}

#layoutPanel button:not(.placement-mode__btn):not(.orientation-toggle__btn),
#tileToolsPanel button:not(.placement-mode__btn):not(.orientation-toggle__btn),
#chainPanel button:not(.placement-mode__btn):not(.orientation-toggle__btn){padding:4px 6px;font-size:10px;border-radius:6px}
#chainPanel .chain-actions .link,#chainPanel .chain-buttons button{padding:4px 6px}

label{font-size:11px;color:var(--muted)}
input,select,button,textarea{width:100%;padding:6px;border-radius:8px;border:1px solid var(--border);background:var(--bg);color:var(--text);font-size:11px;line-height:1.3}
textarea{font-family:inherit;line-height:1.4}
header .actions button, header .actions select{width:auto}
button{cursor:pointer;transition:transform .02s ease;line-height:1.3}
button:hover{background:var(--panel);transform:translateY(-1px)}
button:active{transform:translateY(0)}
.actions button{padding:6px 8px}

.toolbox{margin-top:6px}
#sectionList{list-style:none;margin:0;padding:0;max-height:140px;overflow:auto;border:1px dashed var(--border);border-radius:8px}
#sectionList li{display:flex;align-items:center;justify-content:space-between;gap:8px;padding:6px 8px;border-bottom:1px dashed var(--border)}
#sectionList li:last-child{border-bottom:none}
#sectionList .chip{display:inline-flex;align-items:center;gap:6px;padding:2px 8px;border-radius:999px;border:1px solid var(--border);background:var(--chip)}
#sectionList .chip .color{width:12px;height:12px;border-radius:4px;display:inline-block}
#sectionList .section-actions{display:flex;align-items:center;gap:6px;margin-left:auto}
#sectionList .section-actions .section-use{background:var(--panel);border:1px solid var(--border);color:var(--fg);padding:2px 10px;border-radius:6px;font-size:11px;line-height:1.4}
#sectionList .section-actions .section-use:hover{background:var(--chip);color:var(--accent)}
#sectionList .section-actions .section-remove{background:transparent;border:1px solid transparent;color:var(--warn);padding:2px 6px;font-size:11px;line-height:1.4;text-decoration:none;border-radius:6px}
#sectionList .section-actions .section-remove:hover{background:rgba(245,158,11,0.08);text-decoration:underline}

#workspace{display:flex;flex-direction:column;gap:12px;padding-right:4px;min-width:0;min-height:0;overflow:visible;height:auto}
#workspace .panel{margin-bottom:0}
#legendBar{display:flex;align-items:center;gap:8px;padding:6px 10px;border:1px solid var(--border);border-radius:10px;background:var(--panel);box-shadow:var(--shadow);overflow-x:auto;overflow-y:hidden}
#legendBar .legend-item{display:flex;align-items:center;gap:4px;font-size:10px;color:var(--muted);white-space:nowrap}
#legendBar .legend-item--half .legend-half-swatch{display:inline-flex;align-items:center;justify-content:center;width:16px;height:16px;border-radius:5px;border:1px dashed var(--accent-2);color:var(--accent-2);font-weight:600;font-size:10px;background:rgba(148,163,184,0.18)}
#legendBar .legend-title{font-size:10px;text-transform:uppercase;letter-spacing:.1em;color:var(--accent);font-weight:600}
#legendBar .legend-toggle{display:flex;align-items:center;gap:4px;font-size:10px;color:var(--muted)}
#legendBar .legend-toggle input{width:auto;margin:0}
#legendBar .legend-marker-pair{display:inline-flex;align-items:center;gap:2px}
#legendBar .legend-marker-separator{font-size:10px;color:var(--muted)}
#legendBar .legend-clear{width:auto;padding:4px 8px;margin-left:0;font-size:10px;white-space:nowrap}
#toolQuickBar{display:flex;align-items:center;gap:6px;padding:4px 8px;border:1px solid var(--border);border-radius:10px;background:var(--panel);box-shadow:var(--shadow);flex-wrap:nowrap;overflow-x:auto}
#toolQuickBar .tool-quick-title{font-size:8px;text-transform:uppercase;letter-spacing:.16em;color:var(--accent);font-weight:600;margin-right:4px;white-space:nowrap}
.tool-quick-scroll{display:flex;align-items:center;gap:2px;flex:1 1 auto;flex-wrap:nowrap;overflow:visible;padding-bottom:0;min-width:0}
.tool-quick{flex:0 1 auto;display:inline-flex;align-items:center;justify-content:center;padding:2px 5px;border-radius:8px;background:var(--chip);color:var(--accent-2);border:1px solid var(--border);font-size:8px;line-height:1.1;text-transform:uppercase;letter-spacing:.05em;white-space:nowrap;transition:background .15s ease,color .15s ease,transform .02s ease}
.tool-quick:hover{background:var(--panel);color:var(--accent)}
.tool-quick.is-active{background:var(--accent-2);color:#04111d;border-color:var(--accent-2);box-shadow:0 0 0 1px rgba(4,17,29,0.35)}
.tool-quick:focus-visible{outline:2px solid var(--accent-2);outline-offset:2px}

#canvasWrap{position:relative;padding:0;overflow:auto;max-height:82vh;min-height:420px;border:1px solid color-mix(in srgb,var(--border) 82%,rgba(255,255,255,.08));border-radius:18px;background:linear-gradient(180deg,rgba(255,255,255,.04),rgba(255,255,255,.015));box-shadow:0 24px 70px rgba(2,6,23,.16);width:100%;max-width:100%;flex:1 1 auto}
#canvasWrap.design-stage{display:grid;gap:0}
.workspace-chrome{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:10px 14px;overflow:hidden}
.workspace-chrome--after-canvas{margin-top:10px}
.workspace-chrome__meta{display:flex;min-width:0;flex:1}
.workspace-chrome__summary{display:flex;align-items:center;justify-content:space-between;gap:14px;min-width:0;width:100%}
.workspace-chrome__title-group{display:grid;gap:3px;min-width:0}
.workspace-chrome__title-row{display:flex;align-items:center;gap:8px;min-width:0;flex-wrap:wrap}
.workspace-chrome__title-row strong{display:block;font-size:14px;line-height:1.1;color:#f8fafc;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;max-width:100%}
.workspace-chrome__subtitle{display:block;font-size:11px;color:rgba(226,232,240,.72);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.workspace-chrome__mode{display:inline-flex;align-items:center;padding:4px 8px;border-radius:999px;border:1px solid rgba(148,163,184,.22);background:rgba(255,255,255,.06);font-size:10px;font-weight:700;letter-spacing:.08em;text-transform:uppercase;color:var(--accent-2)}
.workspace-chrome__metrics{display:flex;gap:8px;flex-wrap:wrap;justify-content:flex-end}
.workspace-chrome__metric{display:grid;gap:1px;min-width:110px;padding:7px 10px;border-radius:12px;background:rgba(255,255,255,.04);border:1px solid rgba(148,163,184,.14)}
.workspace-chrome__metric span{display:block;margin:0;font-size:10px;letter-spacing:.08em;text-transform:uppercase;color:rgba(148,163,184,.9)}
.workspace-chrome__metric strong{display:block;font-size:12px;font-weight:700;color:#f8fafc}
.workspace-chrome__actions{display:flex;gap:8px;flex-wrap:wrap;justify-content:flex-end}
.workspace-chrome__actions button{width:auto;white-space:nowrap}
.design-stage__canvas-shell{position:relative;padding:18px;display:grid;justify-content:center;align-items:start;min-height:420px;background:
  radial-gradient(circle at top,rgba(56,189,248,.08),transparent 32%),
  radial-gradient(circle at bottom right,rgba(168,85,247,.08),transparent 28%),
  linear-gradient(180deg,rgba(15,23,42,.1),rgba(15,23,42,.02))}
.design-stage__canvas-shell::before{content:'';position:absolute;inset:18px;border-radius:16px;background:
  linear-gradient(90deg,rgba(148,163,184,.08) 1px,transparent 1px),
  linear-gradient(180deg,rgba(148,163,184,.08) 1px,transparent 1px);
background-size:32px 32px;pointer-events:none;mask-image:linear-gradient(180deg,rgba(0,0,0,.8),rgba(0,0,0,.3))}
#canvas{display:block;position:relative;max-width:none;max-height:none;background:linear-gradient(180deg,rgba(255,255,255,.96),rgba(248,250,252,.92));border:1px solid color-mix(in srgb,var(--border) 78%,rgba(255,255,255,.28));border-radius:14px;cursor:crosshair;transition:box-shadow .12s ease, transform .12s ease;box-shadow:0 14px 40px rgba(15,23,42,.16),0 0 0 1px rgba(255,255,255,.45) inset}
#canvas.is-dragging{cursor:grabbing;box-shadow:0 0 0 2px var(--accent-2)}
#canvas.is-drawing-chain{box-shadow:0 0 0 2px rgba(56,189,248,0.35)}
.legend-swatch{position:relative;display:inline-flex;width:22px;height:12px;border-radius:6px;margin-right:6px;vertical-align:middle;overflow:hidden;align-items:center}
.legend-swatch.legend-swatch--data-route::before,.legend-swatch.legend-swatch--power-route::before{content:'';position:absolute;left:2px;right:2px;top:50%;height:3px;border-radius:999px;transform:translateY(-50%)}
.legend-swatch.legend-swatch--data-route::before{background:#38bdf8;box-shadow:0 0 0 2px rgba(6,16,24,0.35)}
.legend-swatch.legend-swatch--power-route::before{background:#facc15;box-shadow:0 0 0 2px rgba(8,10,14,0.28)}
.legend-swatch.legend-swatch--data-accent,.legend-swatch.legend-swatch--power-accent{background:rgba(255,255,255,0.03);border:1px solid rgba(148,163,184,0.18)}
.legend-swatch.legend-swatch--data-accent::before,.legend-swatch.legend-swatch--power-accent::before{content:'';position:absolute;left:1px;right:1px;height:4px;border-radius:999px}
.legend-swatch.legend-swatch--data-accent::before{top:1px;background:linear-gradient(90deg,rgba(56,189,248,0.9),rgba(8,145,178,0.92))}
.legend-swatch.legend-swatch--power-accent::before{bottom:1px;background:linear-gradient(90deg,rgba(250,204,21,0.95),rgba(245,158,11,0.92))}
.legend-swatch.rigging{background:linear-gradient(135deg,#38bdf8 0%,#f97316 50%,#a855f7 100%);border:1px solid rgba(148,163,184,0.45)}
.legend-item--badge{display:flex;align-items:center;gap:6px}
.legend-badge{display:inline-flex;align-items:center;justify-content:center;min-width:26px;height:18px;padding:0 6px;border-radius:999px;font-size:10px;font-weight:700;color:#07131d;box-shadow:0 0 0 1px rgba(0,0,0,0.22)}
.legend-badge--data{background:#38bdf8}
.legend-badge--power{background:#facc15}
.legend-arrow{position:relative;display:inline-flex;width:20px;height:8px;align-items:center}
.legend-arrow::before{content:'';position:absolute;left:0;right:6px;top:50%;height:3px;border-radius:999px;transform:translateY(-50%)}
.legend-arrow::after{content:'';position:absolute;right:0;top:50%;width:0;height:0;transform:translateY(-50%);border-top:5px solid transparent;border-bottom:5px solid transparent}
.legend-arrow--data::before{background:#38bdf8}.legend-arrow--data::after{border-left:7px solid #38bdf8}
.legend-arrow--power::before{background:#facc15}.legend-arrow--power::after{border-left:7px solid #facc15}
.legend-sections{display:flex;flex-wrap:wrap;gap:6px;align-items:center}
.legend-sections .legend-chip{display:inline-flex;align-items:center;gap:4px;padding:2px 6px;border-radius:999px;border:1px solid var(--border);background:var(--chip);color:var(--text);font-size:10px;white-space:nowrap}
.legend-sections .legend-chip .color{width:10px;height:10px;border-radius:4px;display:inline-block}
.legend-sections .legend-empty{font-size:10px;color:var(--muted);white-space:nowrap}
.legend-actions{margin-left:auto;display:flex;gap:8px;flex-wrap:wrap;align-items:center}
.legend-actions button{width:auto;white-space:nowrap}

button.link{background:transparent;color:var(--muted);border:1px dashed var(--border);text-transform:uppercase;font-size:10px;lett
er-spacing:.08em;padding:6px 8px;width:auto}
button.link:hover{color:var(--accent);border-color:var(--accent);background:rgba(249,115,22,0.08)}

.tile-tools-grid,.chain-tools-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(220px,1fr));gap:10px}
.tile-tools-grid{margin-top:8px}
.chain-tools-grid--compact{margin-top:8px}
.numbering-card,.chain-card{background:var(--panel);border:1px solid var(--border);border-radius:8px;padding:10px;display:flex;flex-direction:column;gap:8px}
.numbering-card h3,.chain-card h3{margin:0;font-size:12px;color:var(--accent)}
.numbering-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(160px,1fr));gap:8px}
.numbering-grid label{display:flex;flex-direction:column;gap:4px;font-size:11px;color:var(--muted)}
.numbering-grid select{margin-top:2px}
.numbering-lock{margin-top:8px;display:flex;flex-direction:column;gap:6px}
.numbering-lock__toggle{display:inline-flex;align-items:center;gap:8px;font-size:12px;font-weight:600;color:var(--text);white-space:nowrap}
.numbering-lock__toggle span{line-height:1}
.numbering-lock__toggle input{margin:0}
.numbering-lock p{margin:0;font-size:10px;color:var(--muted);line-height:1.3}

@media (max-width:600px){
  .section-actions{flex-direction:column;align-items:stretch}
  .section-actions button{width:100%}
  .section-actions #sectionColor{width:100%}
}
.chain-hint{font-size:11px;color:var(--muted);margin:2px 0 0 0}
.chain-buttons{display:flex;flex-wrap:wrap;gap:8px}
.chain-buttons button{flex:1 1 160px}
.chain-actions{display:flex;flex-wrap:wrap;gap:8px;margin-top:4px}
.chain-actions .link{flex:1 1 140px}
.chain-status{margin-top:6px;font-size:11px;color:var(--muted);min-height:16px;opacity:0;transition:opacity .2s ease}
.chain-status.visible{opacity:1}
.chain-status.success{color:var(--accent-2)}
.chain-status.warn{color:var(--warn)}
.chain-status.error{color:#f87171}
.chain-status.info{color:var(--muted)}
.chain-editor-card{background:var(--panel);border:1px solid var(--border);border-radius:8px;padding:10px;display:flex;flex-direction:column;gap:8px}
.chain-editor-card h3{margin:0;font-size:12px;color:var(--accent)}
.chain-editor-card h4{margin:0 0 4px 0;font-size:11px;color:var(--muted);text-transform:uppercase;letter-spacing:.08em}
.chain-editor__groups{display:grid;grid-template-columns:repeat(auto-fit,minmax(200px,1fr));gap:10px}
.chain-editor__list{display:flex;flex-direction:column;gap:6px}
.chain-editor__item{display:flex;align-items:center;justify-content:space-between;gap:8px;padding:6px 8px;border:1px solid var(--border);border-radius:8px;background:var(--bg)}
.chain-editor__label{font-weight:600;color:var(--accent-2);font-size:11px}
.chain-editor__details{font-size:11px;color:var(--muted)}
.chain-editor__info{display:flex;align-items:center;gap:8px;flex:1 1 auto;min-width:0}
.chain-editor__actions{display:flex;align-items:center;gap:8px}
.chain-editor__color-input{width:28px;height:28px;padding:0;border:1px solid var(--border);border-radius:6px;background:transparent;cursor:pointer}
.chain-editor__color-input::-webkit-color-swatch{border:none;border-radius:4px}
.chain-editor__color-input::-moz-color-swatch{border:none;border-radius:4px}
.chain-editor__color-input:focus-visible{outline:2px solid var(--accent);outline-offset:2px}
.chain-editor__disconnect{width:auto}

.control-card--aspect .aspect-readout{display:flex;flex-direction:column;gap:6px;font-size:11px;color:var(--muted)}
.control-card--aspect .aspect-row{display:flex;justify-content:space-between;align-items:center;gap:8px}
.control-card--aspect .aspect-label{font-weight:600;color:var(--accent-2);text-transform:uppercase;letter-spacing:.06em}
.control-card--aspect .aspect-value{color:var(--text);font-weight:500}
.control-card--aspect .aspect-note{margin:0;color:var(--muted);font-size:10px;min-height:14px}
.control-card--aspect select{margin-bottom:4px}

#summaryPanel h2{margin:0 0 8px;font-size:14px;color:var(--accent-2);letter-spacing:0.2px}
.workspace-lower{display:flex;flex-direction:column;gap:12px}

body.app-presentation-mode #legendBar,
body.app-presentation-mode .workspace-lower{display:none}
body.app-presentation-mode .design-stage{border-color:color-mix(in srgb,var(--accent-2) 24%,var(--border));box-shadow:0 0 0 1px rgba(125,211,252,.18),0 24px 80px rgba(2,6,23,.34)}
body.app-presentation-mode #legendBar,
body.app-presentation-mode .workspace-lower{display:none}
body.app-presentation-mode .workspace-chrome{border-color:color-mix(in srgb,var(--accent-2) 24%,var(--border));box-shadow:0 0 0 1px rgba(125,211,252,.12),0 16px 42px rgba(2,6,23,.26)}
body.app-presentation-mode .workspace-chrome__mode{background:rgba(15,23,42,.58);border-color:rgba(125,211,252,.18)}
body.app-presentation-mode .workspace-chrome__actions #btnDesignPresentationMode{background:var(--accent-2);color:#04111d;border-color:transparent}
body.app-presentation-mode .design-stage{border-color:color-mix(in srgb,var(--accent-2) 24%,var(--border));box-shadow:0 0 0 1px rgba(125,211,252,.18),0 24px 80px rgba(2,6,23,.34)}
body.app-presentation-mode .design-stage__canvas-shell{padding:24px;min-height:520px;background:
  radial-gradient(circle at top,rgba(34,197,94,.08),transparent 28%),
  radial-gradient(circle at bottom right,rgba(56,189,248,.12),transparent 24%),
  linear-gradient(180deg,rgba(15,23,42,.14),rgba(15,23,42,.04))}
@media (max-width: 1120px){
  .workspace-chrome,.workspace-chrome__summary{align-items:flex-start}
  .workspace-chrome{flex-direction:column}
  .workspace-chrome__summary{flex-direction:column;justify-content:flex-start}
  .workspace-chrome__metrics{justify-content:flex-start}
}
@media (max-width: 820px){
  .workspace-chrome__actions{width:100%;justify-content:flex-start}
  .workspace-chrome__metric{min-width:96px}
}

footer{
  margin-top:16px;
  padding:12px 16px;
  border-top:1px solid var(--border);
  background:var(--panel);
}

.footer-content{
  display:grid;
  grid-template-columns:minmax(0,1fr) auto minmax(0,1fr);
  align-items:center;
  gap:16px;
  width:100%;
}

.footer-brand{
  justify-self:start;
  display:block;
  color:var(--muted);
  font-size:12px;
  line-height:1.4;
}

.footer-content > .footer-link{
  justify-self:center;
}

footer .footer-links{
  justify-self:end;
}

@media (max-width: 960px){
  .footer-content{
    grid-template-columns:1fr;
    justify-items:start;
    gap:10px;
  }

  .footer-content > .footer-link,
  footer .footer-links{
    justify-self:start;
  }
}

footer .footer-brand a{color:var(--accent-2);text-decoration:none;font-weight:600}
footer .footer-brand a:hover,footer .footer-brand a:focus{color:var(--accent);text-decoration:underline;outline:none}
footer .footer-links{display:flex;align-items:center;gap:12px;flex-wrap:wrap}
.footer-link{background:transparent;border:none;color:var(--accent-2);font-size:12px;font-weight:600;letter-spacing:.05em;text-transform:uppercase;cursor:pointer;padding:0;transition:color .15s ease;text-decoration:none;flex:0 0 auto;width:auto}
.footer-link:hover,.footer-link:focus{color:var(--accent);outline:none;text-decoration:underline}
.footer-link:focus-visible{outline:2px solid var(--accent-2);outline-offset:2px;border-radius:4px}

.legal-modal{position:fixed;inset:0;display:none;align-items:center;justify-content:center;padding:24px;z-index:170}
.legal-modal::before{content:"";position:absolute;inset:0;background:rgba(4,8,12,0.78);backdrop-filter:blur(3px)}
.legal-modal__backdrop{position:absolute;inset:0}
.legal-modal--open{display:flex}
.legal-modal__dialog{position:relative;background:var(--panel);border:1px solid var(--border);border-radius:16px;box-shadow:0 24px 80px rgba(0,0,0,0.65);width:min(720px,calc(100% - 32px));max-height:calc(100vh - 48px);display:flex;flex-direction:column;overflow:hidden}
.legal-modal__header{display:flex;align-items:center;justify-content:space-between;padding:18px 22px;border-bottom:1px solid var(--border)}
.legal-modal__header h2{margin:0;font-size:18px;letter-spacing:.04em;text-transform:uppercase;color:var(--accent-2)}
.legal-modal__close{background:var(--chip);border:1px solid var(--border);color:var(--muted);font-size:20px;line-height:1;width:34px;height:34px;border-radius:999px;display:flex;align-items:center;justify-content:center;cursor:pointer;transition:background .15s ease,color .15s ease}
.legal-modal__close:hover,.legal-modal__close:focus{background:var(--accent-2);color:#04111d;outline:none}
.legal-modal__body{padding:20px 24px;overflow:auto;display:flex;flex-direction:column;gap:12px;color:var(--text)}
.legal-modal__body p{margin:0;font-size:13px;line-height:1.6}
.legal-modal__body a{color:var(--accent-2);text-decoration:underline}
.legal-modal__body a:hover,.legal-modal__body a:focus{color:var(--accent);outline:none}
.legal-modal__footer{display:flex;justify-content:flex-end;padding:16px 22px;border-top:1px solid var(--border);background:var(--panel)}
#summary{font-size:12px;color:var(--text);line-height:1.5}
#summary strong{color:var(--accent-2)}
#summary .summary-stack{display:flex;flex-direction:column;gap:8px}
#summary .summary-card{background:var(--panel);border:1px solid var(--border);border-radius:8px;padding:8px}
#summary .summary-card h3{margin:0 0 6px 0;font-size:12px;color:var(--accent)}
#summary .summary-card.summary-card--collapsible{padding:0;overflow:hidden}
#summary .summary-card--collapsible .summary-card__header{display:flex;align-items:center;justify-content:space-between;padding:8px 10px;border-bottom:1px solid var(--border);gap:8px}
#summary .summary-card--collapsible .summary-card__header h3{margin:0;font-size:12px;color:var(--accent)}
#summary .summary-card__toggle{width:auto;padding:2px;border:none;background:transparent;color:var(--muted);display:inline-flex;align-items:center;justify-content:center;border-radius:6px;cursor:pointer;transition:color .15s ease,background .15s ease}
#summary .summary-card__toggle:hover{color:var(--accent-2);background:rgba(249,115,22,0.08)}
#summary .summary-card__toggle:focus-visible{outline:2px solid var(--accent-2);outline-offset:2px}
#summary .summary-card__toggle-icon{display:inline-block;font-size:12px;transition:transform .2s ease}
#summary .summary-card--collapsed .summary-card__toggle-icon{transform:rotate(-90deg)}
#summary .summary-card__body{padding:10px}
#summary .summary-card--collapsed .summary-card__body{display:none}
#summary .summary-card__body > *:first-child{margin-top:0}
#summary .summary-card__body > *:last-child{margin-bottom:0}
#summary .summary-card.summary-card--walls:not(.summary-card--collapsed) .summary-card__body{display:flex;flex-direction:column;gap:8px}
#summary .summary-wall{display:flex;flex-direction:column;gap:8px;padding:8px;border:1px solid var(--border);border-radius:8px;background:var(--bg)}
#summary .summary-wall__header{display:flex;justify-content:space-between;align-items:center}
#summary .summary-wall__title{display:flex;align-items:center;gap:8px}
#summary .summary-wall__title h4{margin:0;font-size:12px;color:var(--accent-2)}
#summary .summary-wall__badges{display:flex;gap:6px;flex-wrap:wrap}
#summary .summary-pill{display:inline-flex;align-items:center;justify-content:center;padding:2px 8px;border-radius:999px;background:var(--chip);border:1px solid var(--border);font-size:10px;color:var(--muted);text-transform:uppercase;letter-spacing:.08em}
#summary .summary-pill--accent{background:var(--accent-2);color:#04111d;border-color:var(--accent-2)}
#summary .summary-pill--muted{color:var(--muted)}
#summary .summary-wall__metrics{display:grid;grid-template-columns:repeat(auto-fit,minmax(140px,1fr));gap:6px}
#summary .summary-wall__metrics .label{display:block;font-size:10px;color:var(--muted);text-transform:uppercase;letter-spacing:.04em}
#summary .summary-wall__metrics .value{display:block;font-size:12px;color:var(--text);font-weight:600}
#summary .summary-wall__support{font-size:11px;color:var(--muted);line-height:1.4;background:rgba(15,23,30,0.6);border:1px dashed var(--border);border-radius:6px;padding:6px}
#summary .summary-wall--empty{opacity:0.7}
#summary .summary-meta{display:grid;grid-template-columns:repeat(auto-fit,minmax(140px,1fr));gap:6px}
#summary .summary-meta .label{display:block;font-size:10px;color:var(--muted);text-transform:uppercase;letter-spacing:.04em}
#summary .summary-meta .value{display:block;font-size:12px;color:var(--text);font-weight:600}
#summary .summary-meta .value small{color:var(--muted);font-weight:400}
#summary .summary-note{margin:6px 0 0 0;font-size:11px;color:var(--muted)}
#summary .summary-confidence{display:flex;flex-direction:column;gap:10px}
#summary .summary-confidence__header{display:flex;flex-direction:column;gap:6px}
#summary .summary-confidence__headline{display:flex;align-items:center;justify-content:space-between;gap:8px;flex-wrap:wrap}
#summary .summary-status{display:inline-flex;align-items:center;justify-content:center;padding:3px 9px;border-radius:999px;border:1px solid var(--border);background:var(--chip);font-size:10px;font-weight:700;letter-spacing:.08em;text-transform:uppercase}
#summary .summary-status--success{color:#5eead4;border-color:rgba(94,234,212,0.35);background:rgba(20,184,166,0.12)}
#summary .summary-status--info{color:var(--accent-2);border-color:rgba(249,115,22,0.35);background:rgba(249,115,22,0.12)}
#summary .summary-status--warn{color:var(--warn);border-color:rgba(245,158,11,0.35);background:rgba(245,158,11,0.12)}
#summary .summary-status--muted{color:var(--muted)}
#summary .summary-confidence__score{font-size:16px;color:var(--text)}
#summary .summary-confidence__meta{margin-top:2px}
#summary .summary-confidence__reasons{margin:0 0 0 16px;padding:0;display:flex;flex-direction:column;gap:4px;font-size:11px;color:var(--text)}
#summary .summary-guidance{display:grid;grid-template-columns:repeat(auto-fit,minmax(220px,1fr));gap:8px}
#summary .summary-guidance__item{display:flex;flex-direction:column;gap:6px;padding:8px;border-radius:8px;border:1px solid var(--border);background:rgba(15,23,30,0.65)}
#summary .summary-guidance__item--warn{border-color:rgba(245,158,11,0.35);background:rgba(245,158,11,0.08)}
#summary .summary-guidance__item--info{border-color:rgba(249,115,22,0.22)}
#summary .summary-guidance__header{display:flex;align-items:center;gap:8px;flex-wrap:wrap}
#summary .summary-guidance__header h4{margin:0;font-size:12px;color:var(--text)}
#summary .summary-guidance__badge{display:inline-flex;align-items:center;justify-content:center;padding:2px 7px;border-radius:999px;background:var(--chip);border:1px solid var(--border);font-size:10px;font-weight:700;letter-spacing:.08em;text-transform:uppercase;color:var(--muted)}
#summary .summary-guidance__item p{margin:0;font-size:11px;color:var(--muted);line-height:1.45}
#summary .summary-guidance__item ul{margin:0 0 0 16px;padding:0;display:flex;flex-direction:column;gap:4px;font-size:11px;color:var(--text)}
#summary .summary-link{display:inline-block;margin-top:6px;font-size:11px;color:var(--accent-2);text-decoration:none}
#summary .summary-link:hover{text-decoration:underline}
#summary .summary-totals{display:grid;grid-template-columns:repeat(auto-fit,minmax(160px,1fr));gap:6px}
#summary .summary-totals .label{display:block;font-size:10px;color:var(--muted);text-transform:uppercase;letter-spacing:.04em}
#summary .summary-totals .value{display:block;font-size:12px;color:var(--accent-2);font-weight:600}
#summary .summary-totals .value small{display:block;font-size:10px;color:var(--muted);font-weight:400}
#summary .summary-warnings{margin-top:8px;color:var(--warn);font-size:11px}
#summary .summary-warnings ul{margin:4px 0 0 16px;padding:0}
#summary .summary-details{margin-top:8px;font-size:11px}
#summary .summary-chains{display:grid;grid-template-columns:repeat(auto-fit,minmax(160px,1fr));gap:8px;margin-top:6px}
#summary .summary-chains ol{margin:4px 0 0 16px;padding:0;font-size:11px}
#summary .summary-chains li{margin-bottom:4px}
#summary .summary-chains li:last-child{margin-bottom:0}
#summary .chain-label{display:inline-block;min-width:38px;margin-right:6px;color:var(--accent-2);font-weight:600}

/* Density tweaks */
body.density-compact header{padding:6px 10px}
body.density-compact main{grid-template-columns:300px 1fr;padding:10px}
body.density-compact section{padding:6px;border-radius:8px}
body.density-compact input, body.density-compact select, body.density-compact button{padding:5px}
body.density-compact .grid3{gap:4px}
body.density-compact .preset-columns{gap:8px}
body.density-compact .preset-column{gap:6px}
body.density-compact .preset-columns .preset-field{grid-template-columns:minmax(90px,auto) 1fr;gap:4px}
body.density-compact .row{gap:4px;margin-top:4px}
body.density-compact #canvasWrap{max-height:68vh}
body.density-compact #presetPanels{gap:8px}
body.density-compact #presetPanels .spec-panel{padding:8px}

/* Canvas tile styles */

#sidebar section h2{letter-spacing:0.2px}

#presetPanels{display:flex;flex-direction:column;gap:12px;margin-bottom:18px}
#presetPanels .spec-panel{background:var(--panel);border:1px solid var(--border);border-radius:10px;padding:10px;box-shadow:var(--shadow)}
#presetPanels .spec-panel summary{font-size:13px;font-weight:600;color:var(--accent);display:flex;align-items:center;justify-content:space-between}
#presetPanels .spec-panel summary::-webkit-details-marker{display:none}
#presetPanels .spec-panel summary::after{content:'\25bc';font-size:10px;color:var(--muted);transition:transform .2s ease}
#presetPanels .spec-panel[open] summary::after{transform:rotate(180deg)}
#presetPanels .spec-panel .collapsible-body{margin-top:12px;display:flex;flex-direction:column;gap:10px}
.preset-group{display:flex;flex-direction:column;gap:8px}
.preset-group--inline{display:flex;flex-wrap:wrap;gap:8px;align-items:flex-end}
.preset-group--status{display:flex;flex-wrap:wrap;gap:8px;align-items:center}
.preset-apply{width:auto;align-self:stretch;padding:10px 16px}
.preset-field{display:flex;flex-direction:column;gap:4px;font-size:11px;color:var(--muted);min-width:0}
.preset-field span{font-size:11px;color:var(--muted);font-weight:600;letter-spacing:.02em;text-transform:uppercase}
.preset-field select,.preset-field input{width:100%}
.preset-field--grow{flex:1 1 180px}
.preset-group--inline .preset-field{flex:1 1 160px}
.preset-group--inline .preset-field select{min-height:32px}
.preset-group--inline .preset-field span{margin-bottom:2px}
.preset-columns{display:grid;grid-template-columns:repeat(auto-fit,minmax(210px,1fr));gap:12px}
.preset-columns--advanced{grid-template-columns:repeat(auto-fit,minmax(180px,1fr))}
.preset-column{display:flex;flex-direction:column;gap:8px}
.preset-columns .preset-field{display:grid;grid-template-columns:minmax(110px,auto) 1fr;align-items:center;gap:6px;font-size:12px;color:var(--muted-strong, var(--muted))}
.preset-columns .preset-field span{text-transform:none;font-size:12px;color:var(--muted);letter-spacing:.01em}
.preset-columns .preset-field input,.preset-columns .preset-field select{width:100%}
.preset-advanced{border:1px dashed var(--border);border-radius:10px;padding:10px;background:rgba(15,20,28,0.35)}
.preset-advanced summary{cursor:pointer;font-size:11px;font-weight:600;color:var(--accent-2);text-transform:uppercase;letter-spacing:.08em}
.preset-advanced[open] summary{margin-bottom:8px}
#btn-fill-wall{border:1px dashed var(--border)}

input[type=range]{accent-color:var(--accent-2);background:transparent}
#legendBar .legend-item--half{gap:6px}


#summary .summary-card.summary-card--pixel-map:not(.summary-card--collapsed) .summary-card__body{display:flex;flex-direction:column;gap:10px}
#summary .pixel-map__meta{display:grid;grid-template-columns:repeat(auto-fit,minmax(140px,1fr));gap:6px}
#summary .pixel-map__meta .label{display:block;font-size:10px;color:var(--muted);text-transform:uppercase;letter-spacing:.04em}
#summary .pixel-map__meta .value{display:block;font-size:12px;color:var(--text);font-weight:600}
#summary .pixel-map__grid{display:grid;grid-template-columns:repeat(var(--pixel-map-cols),minmax(46px,1fr));grid-template-rows:repeat(var(--pixel-map-rows),minmax(46px,auto));gap:6px;padding:8px;border:1px solid var(--border);border-radius:10px;background:linear-gradient(180deg,rgba(17,22,31,0.88),rgba(10,16,23,0.96))}
#summary .pixel-map__tile{position:relative;display:flex;flex-direction:column;gap:3px;justify-content:space-between;padding:7px 8px;border-radius:8px;border:1px solid rgba(103,132,165,0.35);background:linear-gradient(180deg,rgba(32,44,61,0.96),rgba(16,23,33,0.96));box-shadow:inset 0 1px 0 rgba(255,255,255,0.05)}
#summary .pixel-map__tile::before{content:'';position:absolute;left:3px;right:3px;top:3px;height:4px;border-radius:999px;background:linear-gradient(90deg,rgba(56,189,248,0.9),rgba(8,145,178,0.92))}
#summary .pixel-map__tile--half{border-style:dashed}
#summary .pixel-map__tile--half::before{background:linear-gradient(90deg,rgba(250,204,21,0.95),rgba(245,158,11,0.92))}
#summary .pixel-map__tile-id{font-size:10px;font-weight:700;color:var(--accent-2);text-transform:uppercase;letter-spacing:.04em}
#summary .pixel-map__tile-pos{font-size:12px;font-weight:700;color:var(--text)}
#summary .pixel-map__tile-size{font-size:10px;color:var(--muted)}
#summary .pixel-map__note{font-size:11px;color:var(--muted);line-height:1.45;margin:0}

#summary .summary-pill--success{background:rgba(34,197,94,0.18);color:#bbf7d0;border-color:rgba(34,197,94,0.34)}
#summary .summary-pill--warn{background:rgba(245,158,11,0.16);color:#fde68a;border-color:rgba(245,158,11,0.32)}

#summary .summary-card--provenance .summary-card__body,
#summary [data-summary-id="provenance"] .summary-card__body{display:flex;flex-direction:column;gap:10px}
#summary .summary-provenance{display:flex;flex-direction:column;gap:10px}
#summary .summary-provenance__links,
#summary .summary-provenance__assumptions{margin:6px 0 0 16px;padding:0;font-size:11px;color:var(--text)}
#summary .summary-provenance__links li,
#summary .summary-provenance__assumptions li{margin-bottom:5px}
#summary .summary-provenance__links li:last-child,
#summary .summary-provenance__assumptions li:last-child{margin-bottom:0}


/* v13 legend, curve guide, and compact summary polish */
#legendBar{
  display:flex;
  flex-direction:column;
  gap:8px;
  padding:8px 10px;
  overflow:visible;
}
#legendBar .legend-bar__top{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:10px;
  flex-wrap:wrap;
}
#legendBar .legend-bar__body{
  display:grid;
  grid-template-columns:repeat(auto-fit,minmax(220px,1fr));
  gap:8px 14px;
}
#legendBar .legend-group{
  display:flex;
  flex-wrap:wrap;
  gap:6px 12px;
  align-items:center;
  min-width:0;
}
#legendBar .legend-group--toggles{justify-content:flex-start}
#legendBar .legend-title{font-size:10px;letter-spacing:.12em}
#legendBar .legend-item{font-size:10px;white-space:nowrap}
#legendBar .legend-toggle{font-size:10px;padding:2px 0}
#legendBar .legend-actions{margin-left:0;display:flex;gap:6px;flex-wrap:wrap;align-items:center}
#legendBar .legend-actions button{padding:4px 8px;font-size:10px}
.legend-swatch.legend-swatch--curve-guide{
  background:rgba(255,255,255,0.03);
  border:1px solid rgba(192,132,252,0.32);
}
.legend-swatch.legend-swatch--curve-guide::before{
  content:'';
  position:absolute;
  left:3px;
  right:3px;
  top:1px;
  bottom:3px;
  border-top:2px solid #c084fc;
  border-radius:999px 999px 0 0 / 8px 8px 0 0;
  opacity:0.95;
}
.legend-swatch.legend-swatch--curve-guide::after{
  content:'';
  position:absolute;
  left:6px;
  right:6px;
  bottom:2px;
  height:2px;
  border-radius:999px;
  background:rgba(192,132,252,0.3);
}
@media (max-width: 1180px){
  #legendBar .legend-bar__body{grid-template-columns:1fr 1fr}
}
@media (max-width: 760px){
  #legendBar .legend-bar__body{grid-template-columns:1fr}
}
#summaryPanel h2{margin:0 0 6px;font-size:13px}
.workspace-lower{gap:8px}
#summary{font-size:11px;line-height:1.4}
#summary .summary-stack{display:flex;flex-direction:column;gap:6px}
#summary .summary-card{padding:6px;border-radius:8px}
#summary .summary-card--collapsible .summary-card__header{padding:6px 8px}
#summary .summary-card__body{padding:8px}
#summary .summary-card h3,
#summary .summary-card--collapsible .summary-card__header h3{font-size:11px}
#summary .summary-wall{gap:6px;padding:6px}
#summary .summary-wall__metrics{grid-template-columns:repeat(auto-fit,minmax(110px,1fr));gap:4px}
#summary .summary-wall__metrics .label,
#summary .summary-meta .label,
#summary .summary-totals .label,
#summary .pixel-map__meta .label{font-size:9px}
#summary .summary-wall__metrics .value,
#summary .summary-meta .value,
#summary .summary-totals .value,
#summary .pixel-map__meta .value{font-size:11px}
#summary .summary-meta{grid-template-columns:repeat(auto-fit,minmax(110px,1fr));gap:4px}
#summary .summary-totals{grid-template-columns:repeat(auto-fit,minmax(120px,1fr));gap:4px}
#summary .summary-note{margin:4px 0 0 0;font-size:10px}
#summary .summary-warnings{margin-top:6px;font-size:10px}
#summary .summary-details{margin-top:6px;font-size:10px}
#summary .summary-chains{grid-template-columns:repeat(auto-fit,minmax(140px,1fr));gap:6px;margin-top:4px}
#summary .summary-chains ol{font-size:10px}
#summary .summary-wall__support{padding:5px;font-size:10px}
#summary .pixel-map__grid{grid-template-columns:repeat(var(--pixel-map-cols),minmax(38px,1fr));grid-template-rows:repeat(var(--pixel-map-rows),minmax(38px,auto));gap:4px;padding:6px}
#summary .pixel-map__tile{padding:5px 6px;border-radius:6px}
#summary .pixel-map__tile-id{font-size:9px}
#summary .pixel-map__tile-pos{font-size:10px}
#summary .pixel-map__tile-size{font-size:9px}


/* v14 legend spacing + organization */
#legendBar{
  display:grid;
  grid-template-columns:minmax(0,1fr);
  gap:10px;
  padding:10px 14px;
  overflow:visible;
}
#legendBar .legend-bar__top{
  display:grid;
  grid-template-columns:auto 1fr;
  align-items:center;
  column-gap:14px;
}
#legendBar .legend-actions{
  margin-left:0;
  justify-self:end;
  display:flex;
  gap:8px;
  flex-wrap:wrap;
  align-items:center;
}
#legendBar .legend-bar__body{
  display:grid;
  grid-template-columns:minmax(380px,1.8fr) minmax(240px,1.1fr) minmax(220px,0.9fr);
  gap:18px 26px;
  align-items:start;
}
#legendBar .legend-group{
  display:grid;
  gap:10px 18px;
  align-content:start;
  min-width:0;
}
#legendBar .legend-group--chains{
  grid-template-columns:repeat(3,minmax(0,1fr));
}
#legendBar .legend-group--support{
  grid-template-columns:repeat(2,minmax(0,1fr));
}
#legendBar .legend-group--toggles{
  grid-template-columns:repeat(3,minmax(0,max-content));
  justify-content:end;
  justify-items:start;
  align-items:start;
  padding-left:8px;
  border-left:1px solid rgba(148,163,184,0.12);
}
#legendBar .legend-item,
#legendBar .legend-toggle{
  min-width:0;
  font-size:11px;
  line-height:1.25;
}
#legendBar .legend-item{
  display:flex;
  align-items:center;
  gap:8px;
  color:var(--text);
}
#legendBar .legend-item--badge{gap:8px}
#legendBar .legend-title{font-size:11px;letter-spacing:.16em}
#legendBar .legend-toggle{
  padding:6px 10px;
  border:1px solid var(--border);
  border-radius:999px;
  background:rgba(255,255,255,0.02);
  white-space:nowrap;
}
#legendBar .legend-toggle input{accent-color:#22c55e}
#legendBar .legend-actions button{padding:5px 10px;font-size:10px}
#legendBar .legend-swatch,
#legendBar .legend-half-swatch,
#legendBar .legend-badge,
#legendBar .legend-arrow{flex:0 0 auto}
@media (max-width: 1400px){
  #legendBar .legend-bar__body{
    grid-template-columns:minmax(0,1.25fr) minmax(0,1fr);
  }
  #legendBar .legend-group--toggles{
    grid-column:1 / -1;
    justify-content:start;
    grid-template-columns:repeat(3,minmax(0,max-content));
    padding-left:0;
    border-left:0;
    border-top:1px solid rgba(148,163,184,0.12);
    padding-top:12px;
  }
}
@media (max-width: 1120px){
  #legendBar .legend-bar__top{
    grid-template-columns:1fr;
    row-gap:8px;
  }
  #legendBar .legend-actions{justify-self:start}
  #legendBar .legend-bar__body{
    grid-template-columns:1fr;
    gap:14px;
  }
  #legendBar .legend-group--chains,
  #legendBar .legend-group--support{
    grid-template-columns:repeat(2,minmax(0,1fr));
  }
}
@media (max-width: 760px){
  #legendBar .legend-group--chains,
  #legendBar .legend-group--support,
  #legendBar .legend-group--toggles{
    grid-template-columns:1fr;
  }
}


/* v16 beta review: compact legend, reliable summary collapse, visible curve controls */
#legendBar{padding:4px 10px 6px;gap:6px;overflow:visible}
#legendBar .legend-bar__top{display:grid;grid-template-columns:auto 1fr auto;align-items:center;gap:12px;margin-bottom:4px}
#legendBar .legend-title{font-size:10px;letter-spacing:.18em}
#legendBar .legend-actions{justify-self:end;display:flex;gap:6px;align-items:center}
#legendBar .legend-actions button{padding:4px 8px;font-size:10px}
#legendBar .legend-bar__body{display:grid;grid-template-columns:minmax(430px,1.7fr) minmax(260px,1fr) minmax(200px,.8fr);gap:14px 16px;align-items:center;width:100%}
#legendBar .legend-group{display:grid;gap:8px 14px;align-items:center;min-width:0}
#legendBar .legend-group--chains{grid-template-columns:repeat(3,minmax(120px,1fr))}
#legendBar .legend-group--support{grid-template-columns:repeat(3,minmax(110px,1fr))}
#legendBar .legend-group--toggles{grid-template-columns:repeat(3,minmax(56px,1fr));justify-items:start;padding-left:14px;border-left:1px solid rgba(148,163,184,0.12)}
#legendBar .legend-item{min-width:0;gap:6px;line-height:1.2}
#legendBar .legend-item, #legendBar .legend-toggle{font-size:10px}
#legendBar .legend-toggle{padding:0;border-radius:999px;background:transparent;color:var(--text)}
#legendBar .legend-toggle input{margin-right:4px}
#legendBar .legend-badge{min-width:24px;height:17px;font-size:9px}
#legendBar .legend-arrow{width:18px}
.curve-mode{display:flex;flex-wrap:wrap;gap:6px}
.curve-mode__btn{width:auto;padding:4px 10px;border-radius:999px;background:var(--chip);border:1px solid var(--border);color:var(--muted);font-size:11px;line-height:1.2}
.curve-mode__btn:hover{background:var(--panel);color:var(--accent)}
.curve-mode__btn.is-active{background:var(--accent-2);color:#04111d;border-color:var(--accent-2);box-shadow:0 0 0 1px rgba(4,17,29,.35)}
.curve-mode__btn:disabled{opacity:.45;cursor:not-allowed}
.curve-mode.is-disabled{opacity:.7}
.curve-mode__meta{margin-top:4px;font-size:10px;line-height:1.4;color:var(--muted)}
@media (max-width: 1380px){
  #legendBar .legend-bar__body{grid-template-columns:minmax(320px,1.4fr) minmax(220px,1fr) minmax(180px,.9fr)}
  #legendBar .legend-group--chains{grid-template-columns:repeat(2,minmax(120px,1fr))}
}
@media (max-width: 1180px){
  #legendBar .legend-bar__body{grid-template-columns:1fr;gap:10px}
  #legendBar .legend-group--chains,#legendBar .legend-group--support{grid-template-columns:repeat(3,minmax(110px,1fr))}
  #legendBar .legend-group--toggles{border-left:0;padding-left:0}
}
@media (max-width: 860px){
  #legendBar .legend-group--chains,#legendBar .legend-group--support,#legendBar .legend-group--toggles{grid-template-columns:repeat(2,minmax(110px,1fr))}
  #legendBar .legend-bar__top{grid-template-columns:1fr;align-items:start}
  #legendBar .legend-actions{justify-self:start}
}


/* v17 compact legend + reliable summary defaults */
#legendBar{padding:4px 10px 5px;gap:4px;overflow:visible}
#legendBar .legend-bar__top{display:flex;align-items:center;justify-content:space-between;gap:10px;margin-bottom:2px}
#legendBar .legend-title{font-size:10px;letter-spacing:.18em;line-height:1}
#legendBar .legend-actions{display:flex;gap:6px;align-items:center;flex:0 0 auto}
#legendBar .legend-actions button{padding:3px 8px;font-size:10px}
#legendBar .legend-bar__body{display:flex;flex-wrap:wrap;align-items:center;gap:6px 18px;width:100%}
#legendBar .legend-group{display:flex;flex-wrap:wrap;align-items:center;gap:6px 14px;min-width:0}
#legendBar .legend-group--chains,#legendBar .legend-group--support{flex:1 1 auto}
#legendBar .legend-group--toggles{flex:0 0 auto;margin-left:auto;padding-left:12px;border-left:1px solid rgba(148,163,184,0.12);gap:6px 10px}
#legendBar .legend-item,#legendBar .legend-toggle{font-size:10px;line-height:1.1}
#legendBar .legend-item{gap:5px}
#legendBar .legend-item--badge{gap:6px}
#legendBar .legend-swatch{width:20px;height:10px;margin-right:4px}
#legendBar .legend-half-swatch{width:14px;height:14px;font-size:9px}
#legendBar .legend-badge{min-width:22px;height:16px;font-size:9px}
#legendBar .legend-arrow{width:16px;height:8px}
#legendBar .legend-toggle{padding:0;background:transparent}
#legendBar .legend-toggle input{margin-right:4px}
@media (max-width: 1100px){#legendBar .legend-group--toggles{margin-left:0;padding-left:0;border-left:0}}
@media (max-width: 900px){#legendBar .legend-bar__body{gap:8px 12px}#legendBar .legend-group{flex:1 1 100%}}

/* v17: slightly denser summary cards */
#summary .summary-stack{gap:8px}
#summary .summary-card{padding:8px 10px}
#summary .summary-card__header{margin-bottom:6px}
#summary .summary-meta{gap:6px 12px}
#summary .summary-note{margin-top:6px}


/* v18 compact legend + robust summary details + quick curve bar */
#legendBar{padding:6px 10px}
#legendBar .legend-row{display:flex;align-items:center;gap:10px;flex-wrap:wrap;width:100%}
#legendBar .legend-title{font-size:10px;letter-spacing:.14em;text-transform:uppercase;color:var(--accent);font-weight:700;white-space:nowrap}
#legendBar .legend-items{display:flex;align-items:center;gap:6px 12px;flex-wrap:wrap;min-width:0;flex:1 1 auto}
#legendBar .legend-controls{display:flex;align-items:center;gap:6px 8px;flex-wrap:wrap;justify-content:flex-end;margin-left:auto}
#legendBar .legend-group{display:contents}
#legendBar .legend-item,#legendBar .legend-toggle{font-size:10px;line-height:1.05}
#legendBar .legend-item{gap:4px}
#legendBar .legend-swatch{width:18px;height:8px;border-radius:999px}
#legendBar .legend-half-swatch{width:16px;height:16px;font-size:10px}
#legendBar .legend-badge{min-width:22px;height:20px;font-size:10px;padding:0 6px}
#legendBar .legend-arrow{width:18px}
#legendBar .legend-controls .secondary{padding:5px 8px;font-size:10px;width:auto}
#legendBar .legend-toggle{padding:3px 8px;border-radius:999px;background:rgba(15,23,42,0.5);border:1px solid var(--border)}
#legendBar .legend-toggle input{margin-right:4px}
#legendBar .legend-bar__top{display:none !important}
#legendBar .legend-bar__body{display:block !important;padding:0 !important}
@media (max-width:1100px){#legendBar .legend-controls{flex:1 1 100%;justify-content:flex-start}#legendBar .legend-title{flex:1 1 100%}}

#curveQuickBar{display:flex;align-items:center;gap:10px;flex-wrap:wrap;margin:0 0 8px;background:var(--panel);border:1px solid var(--border);border-radius:10px;padding:8px 10px}
#curveQuickBar[hidden]{display:none !important}
#curveQuickBar .curve-quick-bar__label{font-size:10px;letter-spacing:.12em;text-transform:uppercase;color:var(--accent);font-weight:700}
#curveQuickBar .curve-mode__meta--quick{margin-left:auto;font-size:10px;color:var(--muted)}
@media (max-width: 1100px){#curveQuickBar .curve-mode__meta--quick{margin-left:0;flex:1 1 100%}}

#summary .summary-card--collapsible{padding:0;overflow:hidden}
#summary .summary-card__summary{display:flex;align-items:center;justify-content:space-between;gap:8px;padding:7px 9px;cursor:pointer;list-style:none;border-bottom:1px solid var(--border)}
#summary .summary-card__summary::-webkit-details-marker{display:none}
#summary .summary-card__summary h3{margin:0;font-size:11px;color:var(--accent)}
#summary .summary-card__toggle-icon{display:inline-block;font-size:12px;transition:transform .18s ease;color:var(--muted)}
#summary details.summary-card--collapsible:not([open]) .summary-card__toggle-icon{transform:rotate(-90deg)}
#summary details.summary-card--collapsible:not([open]) .summary-card__body{display:none}
#summary details.summary-card--collapsible[open] .summary-card__body{display:block}
#summary .summary-card__body{padding:8px 9px}
#summary .summary-card--collapsible .summary-card__header,#summary .summary-card__toggle{display:none !important}

#summary .summary-card.summary-card--provenance .summary-card__body,
#summary [data-summary-id="provenance"] .summary-card__body{gap:8px}

#canvasWrap{background:linear-gradient(180deg, rgba(6,18,33,0.95), rgba(5,12,22,0.98))}


/* v19 compact legend + reliable summary collapsibles + curve batch controls */
#legendBar{padding:4px 8px;gap:4px}
#legendBar .legend-row{display:flex;flex-wrap:wrap;align-items:center;gap:8px 12px}
#legendBar .legend-title{font-size:10px;letter-spacing:.16em;flex:0 0 auto;margin-right:2px}
#legendBar .legend-items{display:flex;flex-wrap:wrap;align-items:center;gap:6px 12px;flex:1 1 540px;min-width:0}
#legendBar .legend-item{font-size:10px;gap:5px;white-space:nowrap}
#legendBar .legend-controls{display:flex;flex-wrap:wrap;align-items:center;gap:6px 8px;justify-content:flex-end;flex:0 1 auto;margin-left:auto}
#legendBar .legend-toggle{font-size:10px;padding:0}
#legendBar .legend-controls button{padding:3px 7px;font-size:10px}
#legendBar .legend-badge{min-width:22px;height:16px;font-size:9px}
#legendBar .legend-arrow{width:16px}
#legendBar .legend-swatch{width:16px;height:4px}
#legendBar .legend-half-swatch{width:15px;height:15px;font-size:9px}
.curve-quick-bar{display:flex;flex-wrap:wrap;align-items:center;gap:8px 10px}
.curve-quick-bar__apply{width:auto;padding:4px 9px;font-size:10px;white-space:nowrap}
.curve-mode__meta--quick{flex:1 1 260px;min-width:220px}
#summary .summary-card--collapsible{padding:0;overflow:hidden}
#summary .summary-card--collapsible .summary-card__summary{width:100%;background:transparent;border:0;display:flex;align-items:center;justify-content:space-between;gap:8px;padding:7px 9px;cursor:pointer;border-bottom:1px solid var(--border)}
#summary .summary-card--collapsible .summary-card__summary h3{margin:0;font-size:11px;color:var(--accent)}
#summary .summary-card--collapsible:not(.is-open) .summary-card__body{display:none}
#summary .summary-card--collapsible.is-open .summary-card__toggle-icon{transform:rotate(0deg)}
#summary .summary-card--collapsible:not(.is-open) .summary-card__toggle-icon{transform:rotate(-90deg)}
#summary .summary-card--collapsible .summary-card__toggle-icon{display:inline-block;font-size:12px;color:var(--muted);transition:transform .18s ease}
#summary .summary-card--collapsible .summary-card__body{padding:8px 9px}
@media (max-width: 980px){
  #legendBar .legend-row{gap:6px 10px}
  #legendBar .legend-items{flex-basis:100%}
  #legendBar .legend-controls{margin-left:0;justify-content:flex-start;flex-basis:100%}
}


/* v20 tighter legend + native summary cards + audit card */
#legendBar{padding:3px 8px;gap:3px;border-radius:8px}
#legendBar .legend-row{display:grid;grid-template-columns:auto 1fr auto;align-items:center;gap:8px;width:100%}
#legendBar .legend-title{font-size:9px;letter-spacing:.14em;margin-right:0}
#legendBar .legend-items{display:flex;flex-wrap:wrap;align-items:center;gap:4px 10px;min-width:0}
#legendBar .legend-item{font-size:9px;gap:4px}
#legendBar .legend-controls{display:flex;align-items:center;gap:4px 6px;justify-content:flex-end}
#legendBar .legend-controls button{padding:2px 6px;font-size:9px}
#legendBar .legend-toggle{font-size:9px;padding:0}
#legendBar .legend-swatch{width:14px;height:4px;margin-right:2px}
#legendBar .legend-half-swatch{width:13px;height:13px;font-size:8px}
#legendBar .legend-badge{min-width:18px;height:14px;font-size:8px;padding:0 5px}
#legendBar .legend-arrow{width:14px;height:7px}
@media (max-width: 1200px){#legendBar .legend-row{grid-template-columns:1fr}#legendBar .legend-controls{justify-content:flex-start}}

#summary details.summary-card--collapsible{padding:0;overflow:hidden}
#summary details.summary-card--collapsible > summary{display:flex;align-items:center;justify-content:space-between;gap:8px;padding:7px 9px;cursor:pointer;list-style:none;border-bottom:1px solid var(--border)}
#summary details.summary-card--collapsible > summary::-webkit-details-marker{display:none}
#summary details.summary-card--collapsible > summary h3{margin:0;font-size:11px;color:var(--accent)}
#summary details.summary-card--collapsible[open] > summary .summary-card__toggle-icon{transform:rotate(0deg)}
#summary details.summary-card--collapsible:not([open]) > summary .summary-card__toggle-icon{transform:rotate(-90deg)}
#summary details.summary-card--collapsible > .summary-card__body{padding:8px 9px}
#summary details.summary-card--collapsible:not([open]) > .summary-card__body{display:none}
#summary .summary-card--audit .summary-card__body{display:flex;flex-direction:column;gap:8px}
#summary .summary-card--audit .summary-note{margin:0}


/* v21 next-level polish */
.secondary--ghost{background:transparent;border-style:dashed}
.preset-review-modal__dialog{width:min(860px,calc(100% - 32px))}
.preset-review-modal__body{gap:16px}
.preset-review-modal__body .summary-meta{display:grid;grid-template-columns:repeat(auto-fit,minmax(180px,1fr));gap:10px 14px}
.preset-review-modal__body .summary-meta-item{margin:0}
.preset-review-modal__body strong{color:var(--accent-2)}
.preset-review-modal__body ul{margin:8px 0 0 18px;padding:0;display:grid;gap:6px}
.preset-review-modal__body p{margin:0;color:var(--muted);line-height:1.55}

#legendBar{padding:2px 6px;min-height:auto}
#legendBar .legend-row{grid-template-columns:auto 1fr auto;gap:6px;align-items:center}
#legendBar .legend-title{font-size:9px;letter-spacing:.12em}
#legendBar .legend-items{gap:3px 8px}
#legendBar .legend-item{font-size:9px;gap:3px}
#legendBar .legend-controls{gap:3px 6px}
#legendBar .legend-controls button{padding:2px 5px;font-size:9px}
#legendBar .legend-toggle{font-size:9px}
#legendBar .legend-swatch{width:12px;height:4px}
#legendBar .legend-half-swatch{width:12px;height:12px;font-size:8px}
#legendBar .legend-badge{min-width:16px;height:13px;font-size:8px;padding:0 4px}
#legendBar .legend-arrow{width:12px;height:6px}
@media (max-width: 1180px){#legendBar .legend-row{grid-template-columns:1fr}#legendBar .legend-controls{justify-content:flex-start}}

#summary .summary-card--collapsible{padding:0;overflow:hidden}
#summary .summary-card--collapsible .summary-card__summary{width:100%;background:transparent;border:0;display:flex;align-items:center;justify-content:space-between;gap:8px;padding:6px 8px;cursor:pointer;border-bottom:1px solid var(--border);text-align:left}
#summary .summary-card--collapsible .summary-card__summary h3{margin:0;font-size:11px;color:var(--accent)}
#summary .summary-card--collapsible .summary-card__toggle-icon{display:inline-block;font-size:12px;color:var(--muted);transition:transform .18s ease}
#summary .summary-card--collapsible:not(.is-open) .summary-card__toggle-icon{transform:rotate(-90deg)}
#summary .summary-card--collapsible.is-open .summary-card__toggle-icon{transform:rotate(0deg)}
#summary .summary-card--collapsible .summary-card__body{padding:8px 9px}
#summary .summary-card--collapsible .summary-card__body[hidden]{display:none !important}
#summary .summary-actions{display:flex;justify-content:flex-end;margin-top:6px}
#summary .summary-action-btn{width:auto;padding:4px 8px;font-size:10px}

/* cabinet polish */
.canvas-module-note{font-size:10px;color:var(--muted)}


/* v22 precision polish overrides */
#legendBar{padding:6px 8px !important;border-radius:10px;}
#legendBar .legend-row{display:flex;align-items:center;gap:6px 10px;flex-wrap:nowrap;width:100%;min-height:28px;}
#legendBar .legend-title{font-size:9px;letter-spacing:.12em;text-transform:uppercase;color:var(--accent);flex:0 0 auto;}
#legendBar .legend-items{display:flex;align-items:center;gap:3px 8px;flex-wrap:wrap;min-width:0;flex:1 1 auto;}
#legendBar .legend-item{font-size:8px;gap:3px;line-height:1;white-space:nowrap;color:var(--muted);}
#legendBar .legend-item--badge{gap:4px;}
#legendBar .legend-swatch{width:10px;height:4px;margin-right:0;border-radius:999px;}
#legendBar .legend-half-swatch{width:13px !important;height:13px !important;font-size:8px !important;border-radius:4px !important;}
#legendBar .legend-controls{display:flex;align-items:center;gap:4px 5px;flex-wrap:nowrap;justify-content:flex-end;flex:0 0 auto;margin-left:auto;}
#legendBar .legend-toggle{font-size:8px;padding:1px 5px;border-radius:999px;background:rgba(15,23,42,0.48);border:1px solid var(--border);line-height:1.1;}
#legendBar .legend-toggle input{margin-right:3px;transform:scale(.9);}
#legendBar .legend-controls button{padding:2px 6px;font-size:8px;line-height:1.15;width:auto;}
@media (max-width:1280px){#legendBar .legend-row{flex-wrap:wrap;}#legendBar .legend-controls{flex-basis:100%;justify-content:flex-start;margin-left:0;}}
#summary .summary-card--provenance .summary-card__body[hidden],#summary [data-summary-id="provenance"] .summary-card__body[hidden]{display:none !important;}
#summary .summary-card--provenance .summary-card__body:not([hidden]),#summary [data-summary-id="provenance"] .summary-card__body:not([hidden]){display:flex;flex-direction:column;gap:8px;}
#canvasWrap canvas{image-rendering:auto;}


/* v23 premium polish overrides */
#legendBar{padding:8px 10px;overflow:visible}
#legendBar .legend-row{display:flex;align-items:center;gap:10px;flex-wrap:nowrap}
#legendBar .legend-title{font-size:11px;letter-spacing:.12em;white-space:nowrap}
#legendBar .legend-items{display:flex;align-items:center;gap:12px;flex:1 1 auto;min-width:0;flex-wrap:nowrap}
#legendBar .legend-item{font-size:11px;line-height:1;white-space:nowrap;display:inline-flex;align-items:center;gap:5px}
#legendBar .legend-controls{display:flex;align-items:center;gap:8px;flex:0 0 auto;white-space:nowrap}
#legendBar .legend-toggle{font-size:11px;padding:0}
#legendBar .legend-controls button{font-size:11px;padding:4px 8px}
#legendBar .legend-swatch,#legendBar .legend-half-swatch{transform:scale(1.02)}
#legendBar .legend-badge{font-size:10px;min-width:22px;height:18px}
#legendBar .legend-arrow{width:12px}
#legendBar .legend-item--badge{gap:4px}
@media (max-width: 1360px){
  #legendBar .legend-row{flex-wrap:wrap;align-items:flex-start}
  #legendBar .legend-items{flex-wrap:wrap;gap:8px 12px}
  #legendBar .legend-controls{margin-left:auto}
}
#summary .summary-card--collapsible .summary-card__body[hidden]{display:none!important}
#summary [data-summary-id="provenance"] .summary-card__body[hidden]{display:none!important}
#summary [data-summary-id="provenance"][data-open="false"] .summary-card__body{display:none!important}
#summary [data-summary-id="provenance"][data-open="true"] .summary-card__body{display:flex;flex-direction:column;gap:8px}


/* v24 premium systems polish */
#legendBar{
  padding:5px 10px 5px !important;
  gap:6px !important;
  border-radius:10px !important;
}
#legendBar .legend-row{
  display:grid !important;
  grid-template-columns:auto 1fr auto;
  align-items:center;
  gap:10px;
  width:100%;
}
#legendBar .legend-title{
  font-size:10.5px !important;
  letter-spacing:.14em !important;
  white-space:nowrap;
}
#legendBar .legend-items{
  display:flex !important;
  align-items:center;
  flex-wrap:nowrap;
  gap:6px 11px !important;
  min-width:0;
  overflow:hidden;
}
#legendBar .legend-item,
#legendBar .legend-toggle{
  font-size:10.5px !important;
  line-height:1.1;
  white-space:nowrap;
}
#legendBar .legend-item{gap:5px !important}
#legendBar .legend-controls{
  display:flex !important;
  align-items:center;
  gap:6px 8px;
  justify-content:flex-end;
}
#legendBar .legend-controls button{
  padding:4px 8px !important;
  font-size:10px !important;
}
#legendBar .legend-toggle{
  padding:0 2px !important;
  background:transparent !important;
  border:0 !important;
}
#legendBar .legend-toggle input{margin-right:4px}
#legendBar .legend-swatch{width:16px !important;height:6px !important;margin-right:3px}
#legendBar .legend-half-swatch{width:15px !important;height:15px !important;font-size:9px !important}
#legendBar .legend-badge{min-width:22px !important;height:18px !important;font-size:9px !important;padding:0 6px !important}
#legendBar .legend-arrow{width:16px !important;height:8px !important}
@media (max-width: 1240px){
  #legendBar .legend-row{grid-template-columns:1fr !important;gap:8px}
  #legendBar .legend-items{flex-wrap:wrap !important;overflow:visible}
  #legendBar .legend-controls{justify-content:flex-start}
}

#summary .summary-card--collapsible[data-open="false"] .summary-card__body,
#summary .summary-card--collapsible:not(.is-open) .summary-card__body{
  display:none !important;
}
#summary .summary-card--collapsible[data-open="true"] .summary-card__body,
#summary .summary-card--collapsible.is-open .summary-card__body{
  display:block !important;
}


/* v25 design-area lock: readable legend, tighter gap, stable design UI */
#curveQuickBar{margin:0 0 4px !important;padding:6px 10px !important}
#legendBar{padding:7px 10px !important;margin-top:0 !important;min-height:34px !important;overflow:visible !important}
#legendBar .legend-row{display:flex !important;align-items:center !important;gap:8px !important;flex-wrap:nowrap !important;width:100% !important}
#legendBar .legend-title{font-size:10px !important;letter-spacing:.12em !important;white-space:nowrap !important}
#legendBar .legend-items{display:flex !important;align-items:center !important;gap:8px !important;flex:1 1 auto !important;min-width:0 !important;flex-wrap:nowrap !important}
#legendBar .legend-item{font-size:10px !important;line-height:1 !important;white-space:nowrap !important;display:inline-flex !important;align-items:center !important;gap:5px !important}
#legendBar .legend-controls{display:flex !important;align-items:center !important;gap:6px !important;flex:0 0 auto !important;white-space:nowrap !important}
#legendBar .legend-toggle{font-size:10px !important;padding:0 !important}
#legendBar .legend-controls button{font-size:10px !important;padding:4px 8px !important}
#legendBar .legend-swatch{width:16px !important;height:6px !important;margin-right:3px !important}
#legendBar .legend-half-swatch{width:14px !important;height:14px !important;font-size:9px !important}
#legendBar .legend-badge{font-size:10px !important;min-width:22px !important;height:18px !important}
#legendBar .legend-arrow{width:14px !important}
#canvasWrap{padding:6px 8px 8px !important}
@media (max-width: 1260px){
  #legendBar .legend-row{flex-wrap:wrap !important;align-items:flex-start !important}
  #legendBar .legend-items{flex-wrap:wrap !important;gap:8px 10px !important}
  #legendBar .legend-controls{margin-left:auto !important}
}


.quick-target-coach{gap:8px}
.quick-target-coach__summary{display:flex;flex-direction:column;gap:3px;padding:8px;border-radius:8px;border:1px solid rgba(148,163,184,.18);background:rgba(2,6,23,.22)}
.quick-target-coach__summary strong{font-size:12px;color:var(--text)}
.quick-target-coach__summary span{font-size:10px;color:var(--accent-2)}
.quick-target-coach__actions{margin:0;padding-left:18px;display:flex;flex-direction:column;gap:5px;color:var(--muted)}
.quick-target-coach__actions li{line-height:1.45}
.quick-target-coach__subhead{font-size:10px;font-weight:700;letter-spacing:.08em;text-transform:uppercase;color:var(--accent-2)}
.quick-target-coach__split{display:flex;flex-direction:column;gap:6px}
.quick-target-coach__split-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(170px,1fr));gap:8px}
.quick-target-coach__split-card{display:flex;flex-direction:column;gap:3px;padding:8px;border-radius:8px;border:1px solid rgba(148,163,184,.18);background:rgba(15,23,30,.42)}
.quick-target-coach__split-card strong{font-size:11px;color:var(--text)}
.quick-target-coach__split-card span{font-size:10px;color:var(--muted)}

.quick-target-routing{gap:8px}
.quick-target-routing__summary{display:flex;gap:10px;align-items:stretch;flex-wrap:wrap;padding:8px;border-radius:8px;border:1px solid rgba(148,163,184,.18);background:rgba(2,6,23,.22)}
.quick-target-routing__score{display:flex;flex-direction:column;justify-content:center;min-width:86px;padding:8px;border-radius:8px;background:rgba(15,23,30,.48);border:1px solid rgba(148,163,184,.14)}
.quick-target-routing__score-label{font-size:10px;color:var(--accent-2);text-transform:uppercase;letter-spacing:.06em}
.quick-target-routing__score strong{font-size:24px;line-height:1;color:var(--text)}
.quick-target-routing__summary-copy{display:flex;flex-direction:column;gap:3px;min-width:220px;flex:1}
.quick-target-routing__summary-copy strong{font-size:12px;color:var(--text)}
.quick-target-routing__summary-copy span{font-size:10px;color:var(--muted);line-height:1.45}
.quick-target-routing__actions{margin:0;padding-left:18px;display:flex;flex-direction:column;gap:5px;color:var(--muted)}
.quick-target-routing__actions li{line-height:1.45}
.quick-target-routing__grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(230px,1fr));gap:8px}
.quick-target-routing__card{display:flex;flex-direction:column;gap:8px;padding:10px;border-radius:10px;border:1px solid rgba(148,163,184,.22);background:rgba(15,23,30,.45);min-width:0}
.quick-target-routing__card-top{display:flex;align-items:flex-start;justify-content:space-between;gap:8px}
.quick-target-routing__card-copy{display:flex;flex-direction:column;gap:3px;min-width:0}
.quick-target-routing__card-copy strong{font-size:11px;color:var(--text)}
.quick-target-routing__card-copy span{font-size:10px;color:var(--accent-2)}
.quick-target-routing__card-meta{display:inline-flex;align-items:center;justify-content:center;padding:3px 7px;border-radius:999px;background:rgba(148,163,184,.16);color:var(--accent-2);font-size:10px;font-weight:700;letter-spacing:.05em;text-transform:uppercase;white-space:nowrap}
.quick-target-routing__card-note{margin:0;font-size:10px;line-height:1.45;color:var(--muted)}
.quick-target-routing__outputs{display:grid;grid-template-columns:repeat(auto-fit,minmax(145px,1fr));gap:6px}
.quick-target-routing__output{display:flex;flex-direction:column;gap:2px;padding:7px 8px;border-radius:8px;background:rgba(2,6,23,.24);border:1px solid rgba(148,163,184,.12)}
.quick-target-routing__output strong{font-size:11px;color:var(--text)}
.quick-target-routing__output span{font-size:10px;color:var(--muted);line-height:1.35}
.quick-target-routing__output--hot{border-color:rgba(245,158,11,.38);background:rgba(245,158,11,.08)}
.quick-target-routing__output--tail{border-color:rgba(56,189,248,.28);background:rgba(56,189,248,.08)}


.quick-target-handoff{gap:8px}
.quick-target-handoff__summary{display:flex;gap:10px;align-items:stretch;flex-wrap:wrap;padding:8px;border-radius:8px;border:1px solid rgba(148,163,184,.18);background:rgba(2,6,23,.24)}
.quick-target-handoff__score{display:flex;flex-direction:column;justify-content:center;min-width:96px;padding:8px;border-radius:8px;background:rgba(15,23,30,.48);border:1px solid rgba(148,163,184,.18)}
.quick-target-handoff__score-label{font-size:10px;color:var(--accent-2);text-transform:uppercase;letter-spacing:.06em}
.quick-target-handoff__score strong{font-size:24px;line-height:1;color:var(--text)}
.quick-target-handoff__summary-copy{display:flex;flex-direction:column;gap:3px;min-width:220px;flex:1}
.quick-target-handoff__summary-copy strong{font-size:12px;color:var(--text)}
.quick-target-handoff__summary-copy span{font-size:10px;color:var(--muted);line-height:1.45}
.quick-target-handoff__checklist{margin:0;padding-left:18px;display:flex;flex-direction:column;gap:5px;color:var(--muted)}
.quick-target-handoff__checklist li{line-height:1.45}
.quick-target-handoff__grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(260px,1fr));gap:8px}
.quick-target-handoff__card{display:flex;flex-direction:column;gap:8px;padding:10px;border-radius:10px;border:1px solid rgba(148,163,184,.22);background:rgba(15,23,42,.34)}
.quick-target-handoff__card-top{display:flex;align-items:flex-start;justify-content:space-between;gap:8px}
.quick-target-handoff__card-copy{display:flex;flex-direction:column;gap:3px;min-width:0}
.quick-target-handoff__card-copy strong{font-size:11px;color:var(--text)}
.quick-target-handoff__card-copy span{font-size:10px;color:var(--accent-2);line-height:1.4}
.quick-target-handoff__card-meta{display:inline-flex;align-items:center;justify-content:center;padding:3px 7px;border-radius:999px;background:rgba(148,163,184,.16);border:1px solid rgba(148,163,184,.22);font-size:10px;color:var(--text)}
.quick-target-handoff__card-note{margin:0;font-size:10px;line-height:1.45;color:var(--muted)}
.quick-target-handoff__outputs{display:grid;grid-template-columns:repeat(auto-fit,minmax(160px,1fr));gap:6px}
.quick-target-handoff__output{display:flex;flex-direction:column;gap:2px;padding:7px 8px;border-radius:8px;background:rgba(2,6,23,.24);border:1px solid rgba(148,163,184,.18)}
.quick-target-handoff__output strong{font-size:11px;color:var(--text)}
.quick-target-handoff__output span{font-size:10px;color:var(--muted);line-height:1.35}



.verification-workflow{
  margin-top: 12px;
  padding: 10px 12px;
  border: 1px solid var(--border-color, rgba(148,163,184,0.28));
  border-radius: 12px;
  background: rgba(15, 23, 42, 0.04);
  display: grid;
  gap: 8px;
}

.verification-workflow[hidden]{
  display: none !important;
}

.verification-workflow__toggle{
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.94rem;
}

.verification-workflow__toggle input{
  margin: 0;
}

.verification-workflow__hint{
  margin: 0;
  font-size: 0.85rem;
  color: var(--muted-color, #64748b);
}


.verification-analysis{
  margin-top: 12px;
  padding: 12px;
  border: 1px solid var(--border-color, rgba(148,163,184,0.28));
  border-radius: 12px;
  background: rgba(15, 23, 42, 0.035);
  display: grid;
  gap: 10px;
}

.verification-analysis__toolbar{
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.verification-analysis__toolbar button{
  flex: 1 1 148px;
}

.verification-analysis__hint{
  margin: 0;
  font-size: 0.84rem;
  color: var(--muted-color, #64748b);
}

.verification-analysis__status{
  padding: 10px 12px;
  border-radius: 10px;
  background: rgba(15, 23, 42, 0.06);
  color: var(--muted-color, #64748b);
  font-size: 0.9rem;
}

.verification-analysis__status--ready{
  background: rgba(34, 197, 94, 0.1);
  color: var(--accent-color, #0f172a);
}

.verification-analysis__result{
  display: grid;
  gap: 10px;
  padding: 12px;
  border-radius: 12px;
  border: 1px solid var(--border-color, rgba(148,163,184,0.24));
  background: rgba(248, 250, 252, 0.75);
}

.verification-analysis__summary{
  display: grid;
  grid-template-columns: minmax(96px, 116px) minmax(0, 1fr);
  gap: 12px;
  align-items: center;
}

.verification-analysis__score{
  display: grid;
  gap: 4px;
  justify-items: start;
}

.verification-analysis__score strong{
  font-size: 1.9rem;
  line-height: 1;
}

.verification-analysis__score-label{
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted-color, #64748b);
}

.verification-analysis__copy{
  display: grid;
  gap: 4px;
}

.verification-analysis__copy span{
  color: var(--muted-color, #64748b);
}

.verification-analysis__metrics{
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
  gap: 8px;
  font-size: 0.88rem;
}

.verification-analysis__notes,
.verification-analysis__slice-list{
  margin: 0;
  padding-left: 18px;
  display: grid;
  gap: 6px;
}

.verification-analysis__slice-block{
  display: grid;
  gap: 6px;
}

.verification-analysis__slice-title{
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted-color, #64748b);
}

.verification-analysis__slice-list li{
  display: grid;
  gap: 2px;
}



.verification-rectification{
  margin-top: 12px;
  padding: 12px;
  border-radius: 14px;
  border: 1px solid rgba(148, 163, 184, 0.24);
  background: rgba(15, 23, 42, 0.03);
  display: grid;
  gap: 10px;
}

.verification-rectification[hidden]{
  display: none !important;
}

.verification-rectification__toolbar{
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.verification-rectification__toolbar button{
  flex: 0 1 auto;
}

.verification-rectification__ready{
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border-radius: 999px;
  padding: 6px 10px;
  background: rgba(148, 163, 184, 0.2);
  color: var(--muted-color, #64748b);
  font-size: 0.78rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.verification-rectification__ready.is-ready{
  background: rgba(34, 197, 94, 0.14);
  color: var(--accent-color, #0f172a);
}

.verification-rectification__hint{
  margin: 0;
  font-size: 0.84rem;
  color: var(--muted-color, #64748b);
}

.verification-rectification__status{
  padding: 10px 12px;
  border-radius: 10px;
  background: rgba(15, 23, 42, 0.06);
  color: var(--muted-color, #64748b);
  font-size: 0.84rem;
}

.verification-rectification__status--ready{
  background: rgba(34, 197, 94, 0.1);
  color: var(--accent-color, #0f172a);
}

.verification-rectification__grid{
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 10px;
}

.verification-rectification__panel{
  display: grid;
  gap: 6px;
}

.verification-rectification__label{
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted-color, #64748b);
}

.verification-rectification__canvas{
  width: 100%;
  max-width: 100%;
  border-radius: 12px;
  border: 1px solid rgba(148, 163, 184, 0.28);
  background:
    linear-gradient(45deg, rgba(148, 163, 184, 0.12) 25%, transparent 25%, transparent 75%, rgba(148, 163, 184, 0.12) 75%, rgba(148, 163, 184, 0.12)),
    linear-gradient(45deg, rgba(148, 163, 184, 0.12) 25%, transparent 25%, transparent 75%, rgba(148, 163, 184, 0.12) 75%, rgba(148, 163, 184, 0.12));
  background-size: 18px 18px;
  background-position: 0 0, 9px 9px;
  cursor: crosshair;
}



.verification-analysis__profile{
  display: grid;
  gap: 6px;
  grid-template-columns: minmax(140px, 180px) minmax(0, 1fr);
  align-items: center;
}

.verification-analysis__profile label{
  font-size: 0.84rem;
  color: var(--muted-color, #64748b);
}

.verification-analysis__profile select{
  min-height: 40px;
  border-radius: 10px;
  border: 1px solid var(--border-color, rgba(148,163,184,0.28));
  background: var(--surface-color, #fff);
  color: var(--text-color, #0f172a);
  padding: 0 12px;
}

.verification-analysis__profile-hint{
  margin: 0;
  grid-column: 1 / -1;
  font-size: 0.82rem;
  color: var(--muted-color, #64748b);
}

.verification-analysis__badge{
  display: inline-flex;
  width: fit-content;
  align-items: center;
  border-radius: 999px;
  padding: 5px 10px;
  font-size: 0.74rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  font-weight: 700;
  background: rgba(148,163,184,0.2);
  color: var(--muted-color, #64748b);
}

.verification-analysis__badge--ok{
  background: rgba(34, 197, 94, 0.14);
  color: #166534;
}

.verification-analysis__badge--review{
  background: rgba(245, 158, 11, 0.18);
  color: #92400e;
}

.verification-analysis__badge--warn{
  background: rgba(239, 68, 68, 0.14);
  color: #991b1b;
}

.verification-analysis__tolerance-note{
  padding: 10px 12px;
  border-radius: 10px;
  background: rgba(59, 130, 246, 0.08);
  font-size: 0.86rem;
  color: var(--text-color, #0f172a);
}


.rigging-engineering-status{
  margin-top:10px;
  border:1px solid var(--line);
  border-radius:16px;
  padding:14px;
  background:rgba(255,255,255,0.03);
}
.rigging-engineering-status__header{
  display:flex;
  justify-content:space-between;
  gap:12px;
  align-items:center;
  margin-bottom:10px;
}
.rigging-engineering-status__header strong{
  font-size:14px;
}
.rigging-engineering-status__header span{
  font-size:12px;
  color:var(--muted);
}
.rigging-engineering-status__grid{
  display:grid;
  grid-template-columns:repeat(auto-fit,minmax(140px,1fr));
  gap:10px;
  margin-bottom:10px;
}
.rigging-engineering-status__grid small{
  display:block;
  color:var(--muted);
  margin-bottom:4px;
}
.rigging-engineering-status__grid span{
  font-size:13px;
}
.rigging-engineering-status__note{
  margin:0 0 10px;
  color:var(--muted);
}
.rigging-engineering-status__list{
  margin:0 0 10px 18px;
}
.rigging-engineering-status__checks{
  display:grid;
  grid-template-columns:repeat(auto-fit,minmax(180px,1fr));
  gap:10px;
}
.rigging-engineering-status__check{
  border:1px solid var(--line);
  border-radius:12px;
  padding:10px;
  background:rgba(255,255,255,0.02);
}
.rigging-engineering-status__check span{
  display:inline-block;
  margin-left:8px;
  font-size:11px;
  letter-spacing:0.04em;
  color:var(--muted);
}
.rigging-engineering-status__check small{
  display:block;
  margin-top:6px;
  color:var(--muted);
}
.rigging-engineering-status--pass{
  border-color:rgba(54,179,126,0.45);
  background:rgba(54,179,126,0.08);
}
.rigging-engineering-status--review{
  border-color:rgba(255,193,7,0.45);
  background:rgba(255,193,7,0.08);
}
.rigging-engineering-status--fail{
  border-color:rgba(255,99,71,0.45);
  background:rgba(255,99,71,0.08);
}


.rigging-calibration-status{
  margin-top:12px;
  border-radius:14px;
  border:1px solid rgba(148,163,184,.35);
  background:#f8fafc;
  padding:14px 16px;
  display:grid;
  gap:10px;
}
.rigging-calibration-status--pass{
  border-color:rgba(34,197,94,.35);
  background:rgba(34,197,94,.08);
}
.rigging-calibration-status--review{
  border-color:rgba(245,158,11,.35);
  background:rgba(245,158,11,.08);
}
.rigging-calibration-status--fail{
  border-color:rgba(239,68,68,.35);
  background:rgba(239,68,68,.08);
}
.rigging-calibration-status__header{
  display:flex;
  justify-content:space-between;
  gap:12px;
  align-items:flex-start;
}
.rigging-calibration-status__header span{
  font-size:.9rem;
  color:#475569;
}
.rigging-calibration-status__note,
.rigging-calibration-status__inputs{
  margin:0;
  color:#334155;
}
.rigging-calibration-status__meta{
  display:grid;
  grid-template-columns:repeat(auto-fit,minmax(180px,1fr));
  gap:10px;
}
.rigging-calibration-status__meta-item{
  padding:10px 12px;
  border-radius:12px;
  background:rgba(255,255,255,.7);
  border:1px solid rgba(148,163,184,.25);
  display:grid;
  gap:4px;
}
.rigging-calibration-status__meta-item span{
  font-size:.82rem;
  color:#64748b;
}
.rigging-calibration-status__checks{
  margin:0;
  padding-left:18px;
  display:grid;
  gap:6px;
}


.rigging-case-library{
  margin-top:12px;
  border:1px solid rgba(148,163,184,.3);
  border-radius:14px;
  background:rgba(255,255,255,.75);
  padding:14px 16px;
  display:grid;
  gap:12px;
}
.rigging-case-library__header{
  display:grid;
  gap:4px;
}
.rigging-case-library__header span,
.rigging-case-library__status{
  color:#475569;
  font-size:.92rem;
}
.rigging-case-library__controls{
  display:grid;
  gap:10px;
}
.rigging-case-library__buttons{
  display:flex;
  flex-wrap:wrap;
  gap:8px;
}
.rigging-case-library__matrix{
  display:grid;
  gap:8px;
}

.rigging-case-library__roundtrip{
  display:grid;
  gap:8px;
}
.rigging-roundtrip{
  display:grid;
  gap:10px;
  padding:12px 14px;
  border-radius:12px;
  background:rgba(15,23,42,.03);
  border:1px solid rgba(148,163,184,.25);
}
.rigging-roundtrip--empty{
  background:rgba(148,163,184,.08);
  border-style:dashed;
}
.rigging-roundtrip__summary{
  display:flex;
  flex-wrap:wrap;
  gap:10px 16px;
  align-items:center;
  color:#334155;
  font-size:.92rem;
}
.rigging-roundtrip__note{
  margin:0;
  color:#334155;
  font-size:.92rem;
}
.rigging-roundtrip__issues{
  margin:0;
  padding-left:18px;
  color:#475569;
  font-size:.9rem;
}
.rigging-matrix{
  display:grid;
  gap:10px;
}
.rigging-matrix--empty{
  padding:12px;
  border-radius:12px;
  background:rgba(148,163,184,.08);
  border:1px dashed rgba(148,163,184,.35);
}
.rigging-matrix__summary{
  display:flex;
  flex-wrap:wrap;
  gap:10px 18px;
  color:#334155;
  font-size:.92rem;
}
.rigging-matrix__table-wrap{
  overflow:auto;
}
.rigging-matrix__table{
  width:100%;
  border-collapse:collapse;
  font-size:.92rem;
}
.rigging-matrix__table th,
.rigging-matrix__table td{
  border:1px solid rgba(148,163,184,.25);
  padding:8px 10px;
  vertical-align:top;
  text-align:left;
}
.rigging-matrix__table th{
  background:rgba(241,245,249,.9);
  color:#334155;
  position:sticky;
  top:0;
}
.rigging-matrix__status{
  display:inline-flex;
  align-items:center;
  padding:4px 8px;
  border-radius:999px;
  font-size:.82rem;
  font-weight:600;
  border:1px solid transparent;
  white-space:nowrap;
}
.rigging-matrix__status--pass{
  background:rgba(34,197,94,.1);
  color:#166534;
  border-color:rgba(34,197,94,.25);
}
.rigging-matrix__status--review{
  background:rgba(245,158,11,.12);
  color:#92400e;
  border-color:rgba(245,158,11,.28);
}
.rigging-matrix__status--fail{
  background:rgba(239,68,68,.1);
  color:#991b1b;
  border-color:rgba(239,68,68,.22);
}
#summary .summary-card--calibration-matrix .summary-card__body{
  display:flex;
  flex-direction:column;
  gap:10px;
}

.rigging-case-library__template-field{
  min-width:240px;
  align-self:stretch;
}
.rigging-case-library__template-help{
  margin-top:10px;
  color:#475569;
  font-size:.9rem;
  line-height:1.45;
}

.rigging-case-library__workbook,
.rigging-case-library__diagnostics{
  display:grid;
  gap:8px;
}
.rigging-workbook,
.rigging-import-diagnostics{
  display:grid;
  gap:10px;
  padding:12px 14px;
  border-radius:12px;
  background:rgba(15,23,42,.03);
  border:1px solid rgba(148,163,184,.25);
}
.rigging-workbook--empty,
.rigging-import-diagnostics--empty{
  background:rgba(148,163,184,.08);
  border-style:dashed;
}
.rigging-workbook__header,
.rigging-import-diagnostics__header{
  display:flex;
  flex-wrap:wrap;
  gap:8px 14px;
  justify-content:space-between;
  align-items:flex-start;
}
.rigging-workbook__header p,
.rigging-import-diagnostics__note{
  margin:4px 0 0;
  color:#334155;
  font-size:.92rem;
}
.rigging-workbook__badge{
  display:inline-flex;
  align-items:center;
  padding:5px 10px;
  border-radius:999px;
  background:rgba(226,232,240,.95);
  color:#0f172a;
  font-size:.82rem;
  font-weight:600;
}
.rigging-workbook__meta{
  display:flex;
  flex-wrap:wrap;
  gap:10px 16px;
  color:#334155;
  font-size:.92rem;
}
.rigging-workbook__fields{
  list-style:none;
  margin:0;
  padding:0;
  display:grid;
  grid-template-columns:repeat(auto-fit,minmax(220px,1fr));
  gap:8px;
}
.rigging-workbook__field{
  border:1px solid rgba(148,163,184,.2);
  border-radius:10px;
  background:rgba(255,255,255,.82);
  padding:10px 12px;
  display:grid;
  gap:4px;
}
.rigging-workbook__field span{
  color:#475569;
  font-size:.84rem;
}
.rigging-workbook__field strong{
  color:#0f172a;
  font-size:.92rem;
}
.rigging-workbook__field--missing{
  border-color:rgba(245,158,11,.35);
  background:rgba(254,243,199,.4);
}
.rigging-workbook__issues,
.rigging-workbook__checklist ul,
.rigging-import-diagnostics__list{
  margin:0;
  padding-left:18px;
  color:#475569;
  font-size:.9rem;
}
.rigging-workbook__note{
  margin:0;
  color:#334155;
  font-size:.92rem;
}
.rigging-workbook__checklist{
  display:grid;
  gap:6px;
}
.rigging-import-diagnostics--warn{
  background:rgba(245,158,11,.08);
  border-color:rgba(245,158,11,.28);
}
.rigging-import-diagnostics__header span{
  color:#475569;
  font-size:.84rem;
}

.rigging-case-library__workbook-package,
.rigging-case-library__mapping{
  display:grid;
  gap:8px;
}
.rigging-workbook-package,
.rigging-import-mapping{
  display:grid;
  gap:10px;
  padding:12px 14px;
  border-radius:12px;
  background:rgba(15,23,42,.03);
  border:1px solid rgba(148,163,184,.25);
}
.rigging-workbook-package--empty,
.rigging-import-mapping--empty{
  background:rgba(148,163,184,.08);
  border-style:dashed;
}
.rigging-workbook-package--warn,
.rigging-import-mapping--warn{
  background:rgba(245,158,11,.08);
  border-color:rgba(245,158,11,.28);
}
.rigging-workbook-package__header,
.rigging-import-mapping__header{
  display:flex;
  flex-wrap:wrap;
  justify-content:space-between;
  gap:8px 14px;
  align-items:flex-start;
}
.rigging-workbook-package__header p,
.rigging-import-mapping__note{
  margin:4px 0 0;
  color:#334155;
  font-size:.92rem;
}
.rigging-workbook-package__badge{
  display:inline-flex;
  align-items:center;
  padding:5px 10px;
  border-radius:999px;
  background:rgba(226,232,240,.95);
  color:#0f172a;
  font-size:.82rem;
  font-weight:600;
}
.rigging-workbook-package__files,
.rigging-import-mapping__fields{
  list-style:none;
  margin:0;
  padding:0;
  display:grid;
  gap:8px;
}
.rigging-workbook-package__files li,
.rigging-import-mapping__field{
  display:grid;
  gap:4px;
  border:1px solid rgba(148,163,184,.2);
  border-radius:10px;
  background:rgba(255,255,255,.82);
  padding:10px 12px;
}
.rigging-workbook-package__files li span,
.rigging-import-mapping__field span{
  color:#475569;
  font-size:.84rem;
}
.rigging-workbook-package__files li strong,
.rigging-import-mapping__field strong{
  color:#0f172a;
  font-size:.92rem;
}
.rigging-workbook-package__note{
  margin:0;
  color:#334155;
  font-size:.92rem;
}
.rigging-import-mapping__cases{
  display:grid;
  gap:8px;
}
.rigging-import-mapping__case{
  border:1px solid rgba(148,163,184,.22);
  border-radius:10px;
  background:rgba(255,255,255,.72);
  padding:10px 12px;
  display:grid;
  gap:8px;
}
.rigging-import-mapping__case ul{
  margin:0;
  padding-left:18px;
  color:#475569;
  font-size:.9rem;
}
.rigging-import-mapping__case li{
  display:grid;
  gap:2px;
}
.rigging-import-mapping__field{
  grid-template-columns:minmax(0,1fr) auto;
  align-items:start;
}
.rigging-import-mapping__field-meta{
  display:grid;
  justify-items:end;
  gap:4px;
  color:#64748b;
  font-size:.82rem;
}
.rigging-import-mapping__field--manual{
  border-color:rgba(239,68,68,.24);
}
@media (max-width: 760px){
  .design-stage__header{
    position:static;
    flex-direction:column;
  }
  .design-stage__chips{
    justify-content:flex-start;
  }
  .design-stage__canvas-shell{
    padding:12px;
  }
  .design-stage__canvas-shell::before{
    inset:12px;
  }
  .rigging-import-mapping__field{
    grid-template-columns:1fr;
  }
  .rigging-import-mapping__field-meta{
    justify-items:start;
  }
}



/* Design workspace intelligence */
.design-workspace-panel{
  padding:18px 20px 20px;
  background:linear-gradient(180deg,rgba(13,18,28,0.98) 0%, rgba(10,14,22,0.98) 100%);
  border:1px solid rgba(69,88,114,0.45);
  box-shadow:0 18px 48px rgba(0,0,0,0.28);
}
.design-workspace{
  display:flex;
  flex-direction:column;
  gap:18px;
}
.design-workspace__summary,
.design-workspace__surface{
  display:flex;
  flex-direction:column;
  gap:14px;
}
.design-workspace__body{
  display:grid;
  grid-template-columns:minmax(0,1.15fr) minmax(320px,0.85fr);
  gap:18px;
}
.design-workspace__column{
  min-width:0;
}
.design-workspace__surface{
  padding:16px;
  border-radius:16px;
  background:rgba(17,24,39,0.64);
  border:1px solid rgba(71,85,105,0.34);
}
.design-workspace__section-header{
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:14px;
  flex-wrap:wrap;
}
.design-workspace__section-header h2,
.design-workspace__section-header h3{
  margin:0;
}
.design-workspace__section-header p{
  margin:0;
  color:#9fb0c8;
  font-size:0.92rem;
}
.design-workspace__badge-grid{
  display:grid;
  grid-template-columns:repeat(auto-fit, minmax(175px, 1fr));
  gap:12px;
}
.design-workspace__badge{
  display:flex;
  flex-direction:column;
  gap:8px;
  padding:14px 15px;
  border-radius:15px;
  background:rgba(15,23,36,0.72);
  border:1px solid rgba(86,104,131,0.32);
}
.design-workspace__badge-label{
  font-size:0.78rem;
  letter-spacing:0.08em;
  text-transform:uppercase;
  color:#9fb0c8;
}
.design-workspace__badge-value{
  font-size:1rem;
  line-height:1.25;
}
.design-workspace__badge-detail{
  color:#cbd5e1;
  font-size:0.88rem;
  line-height:1.4;
}
.design-workspace__badge--good{ box-shadow: inset 0 0 0 1px rgba(34,197,94,0.25); }
.design-workspace__badge--warn{ box-shadow: inset 0 0 0 1px rgba(245,158,11,0.28); }
.design-workspace__badge--danger{ box-shadow: inset 0 0 0 1px rgba(248,113,113,0.28); }
.design-workspace__badge--info{ box-shadow: inset 0 0 0 1px rgba(96,165,250,0.28); }
.design-workspace__selection{
  display:flex;
  flex-direction:column;
  gap:12px;
  padding:14px;
  border-radius:14px;
  background:rgba(9,13,20,0.68);
  border:1px solid rgba(71,85,105,0.26);
}
.design-workspace__selection--empty{
  color:#cbd5e1;
}
.design-workspace__selection-pill{
  display:inline-flex;
  align-items:center;
  gap:8px;
  padding:6px 10px;
  border-radius:999px;
  background:rgba(51,65,85,0.72);
  color:#e2e8f0;
  font-size:0.82rem;
}
.design-workspace__facts{
  display:grid;
  grid-template-columns:repeat(auto-fit,minmax(160px,1fr));
  gap:10px 12px;
  margin:0;
}
.design-workspace__fact{
  padding:10px 11px;
  border-radius:12px;
  background:rgba(15,23,36,0.68);
  border:1px solid rgba(71,85,105,0.24);
}
.design-workspace__fact dt{
  margin:0 0 6px;
  font-size:0.78rem;
  text-transform:uppercase;
  letter-spacing:0.06em;
  color:#94a3b8;
}
.design-workspace__fact dd{
  margin:0;
  color:#f8fafc;
  font-weight:600;
}
.design-workspace__routing-list{
  display:grid;
  grid-template-columns:repeat(auto-fit,minmax(180px,1fr));
  gap:12px;
}
.design-workspace__routing-card{
  display:flex;
  flex-direction:column;
  gap:5px;
  padding:12px 13px;
  border-radius:12px;
  background:rgba(15,23,36,0.68);
  border:1px solid rgba(71,85,105,0.24);
}
.design-workspace__routing-card span,
.design-workspace__routing-card small{
  color:#cbd5e1;
}
.design-workspace__suggestions{
  display:flex;
  flex-direction:column;
  gap:12px;
}
.design-workspace__suggestion{
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:12px;
  padding:14px 15px;
  border-radius:14px;
  background:rgba(12,18,28,0.74);
  border:1px solid rgba(71,85,105,0.28);
}
.design-workspace__suggestion-copy{
  display:flex;
  flex-direction:column;
  gap:6px;
}
.design-workspace__suggestion-copy strong{
  font-size:0.96rem;
}
.design-workspace__suggestion-detail{
  margin:0;
  color:#cbd5e1;
  line-height:1.45;
}
.design-workspace__suggestion-action{
  white-space:nowrap;
}
.design-workspace__suggestion--warn{ box-shadow: inset 0 0 0 1px rgba(245,158,11,0.22); }
.design-workspace__suggestion--danger{ box-shadow: inset 0 0 0 1px rgba(248,113,113,0.22); }
.design-workspace__suggestion--info{ box-shadow: inset 0 0 0 1px rgba(96,165,250,0.22); }


.design-workspace__resize-grid{
  display:grid;
  grid-template-columns:repeat(2, minmax(0, 1fr));
  gap:10px;
}
.design-workspace__boundary-grid{
  display:grid;
  grid-template-columns:repeat(2, minmax(0, 1fr));
  gap:10px;
}
.design-workspace__boundary-button{
  display:flex;
  flex-direction:column;
  align-items:flex-start;
  gap:4px;
  padding:12px 13px;
  border-radius:12px;
  border:1px solid rgba(71,85,105,0.34);
  background:rgba(9,13,20,0.72);
  color:#f8fafc;
  text-align:left;
  cursor:pointer;
}
.design-workspace__boundary-button:disabled{
  opacity:0.52;
  cursor:not-allowed;
}
.design-workspace__boundary-button-label{
  font-weight:700;
}
.design-workspace__boundary-button-detail{
  font-size:0.82rem;
  color:#94a3b8;
}
.design-workspace__boundary-button--info{ box-shadow: inset 0 0 0 1px rgba(96,165,250,0.18); }
.design-workspace__boundary-button--warn{ box-shadow: inset 0 0 0 1px rgba(245,158,11,0.18); }
.design-workspace__boundary-button--danger{ box-shadow: inset 0 0 0 1px rgba(248,113,113,0.18); }
.design-workspace__boundary-button--active{
  border-color:rgba(96,165,250,0.52);
  box-shadow:0 0 0 1px rgba(96,165,250,0.22), inset 0 0 0 1px rgba(96,165,250,0.24);
}
.design-workspace__boundary-focus{
  display:flex;
  flex-direction:column;
  gap:12px;
  margin-bottom:14px;
  padding:15px;
  border-radius:14px;
  background:rgba(10,14,22,0.78);
  border:1px solid rgba(71,85,105,0.28);
}
.design-workspace__boundary-focus--info,
.design-workspace__boundary-focus--good{ box-shadow: inset 0 0 0 1px rgba(96,165,250,0.2); }
.design-workspace__boundary-focus--warn{ box-shadow: inset 0 0 0 1px rgba(245,158,11,0.2); }
.design-workspace__boundary-focus--danger{ box-shadow: inset 0 0 0 1px rgba(248,113,113,0.2); }
.design-workspace__boundary-focus-actions{
  display:flex;
  flex-wrap:wrap;
  gap:10px;
}

.design-workspace__quality-reasons{
  display:flex;
  flex-direction:column;
  gap:8px;
  margin:0;
  padding-left:18px;
  color:#dbe7f6;
}
.design-workspace__quality-reasons li{
  line-height:1.45;
  color:#cbd5e1;
}

.design-workspace__resize-button{
  display:flex;
  flex-direction:column;
  align-items:flex-start;
  gap:4px;
  padding:12px 13px;
  border-radius:12px;
  border:1px solid rgba(71,85,105,0.34);
  background:rgba(9,13,20,0.72);
  color:#f8fafc;
  text-align:left;
  cursor:pointer;
}
.design-workspace__resize-button:disabled{
  opacity:0.52;
  cursor:not-allowed;
}
.design-workspace__resize-button-label{
  font-weight:700;
}
.design-workspace__resize-button-detail{
  font-size:0.82rem;
  color:#94a3b8;
}
.design-workspace__resize-button--info{ box-shadow: inset 0 0 0 1px rgba(96,165,250,0.18); }
.design-workspace__resize-button--warn{ box-shadow: inset 0 0 0 1px rgba(245,158,11,0.18); }
.design-workspace__resize-button--danger{ box-shadow: inset 0 0 0 1px rgba(248,113,113,0.18); }
.design-workspace__resize-preview{
  display:flex;
  flex-direction:column;
  gap:14px;
  margin-top:14px;
  padding:15px;
  border-radius:14px;
  background:rgba(10,14,22,0.78);
  border:1px solid rgba(71,85,105,0.28);
}
.design-workspace__resize-preview--good{ box-shadow: inset 0 0 0 1px rgba(34,197,94,0.22); }
.design-workspace__resize-preview--warn{ box-shadow: inset 0 0 0 1px rgba(245,158,11,0.22); }
.design-workspace__resize-preview--danger{ box-shadow: inset 0 0 0 1px rgba(248,113,113,0.22); }
.design-workspace__resize-preview--info{ box-shadow: inset 0 0 0 1px rgba(96,165,250,0.22); }
.design-workspace__resize-comparison{
  display:grid;
  grid-template-columns:minmax(0, 1fr) auto minmax(0, 1fr);
  gap:12px;
  align-items:center;
}
.design-workspace__resize-state{
  display:flex;
  flex-direction:column;
  gap:6px;
  padding:12px;
  border-radius:12px;
  background:rgba(15,23,36,0.68);
  border:1px solid rgba(71,85,105,0.24);
}
.design-workspace__resize-state-label{
  font-size:0.78rem;
  text-transform:uppercase;
  letter-spacing:0.06em;
  color:#94a3b8;
}
.design-workspace__resize-state small{
  color:#cbd5e1;
  line-height:1.45;
}
.design-workspace__resize-arrow{
  color:#93c5fd;
  font-size:1.25rem;
  font-weight:700;
}
.design-workspace__resize-deltas{
  display:grid;
  grid-template-columns:repeat(auto-fit, minmax(140px, 1fr));
  gap:10px;
}
.design-workspace__resize-delta{
  display:flex;
  flex-direction:column;
  gap:5px;
  padding:11px 12px;
  border-radius:12px;
  background:rgba(15,23,36,0.68);
  border:1px solid rgba(71,85,105,0.24);
}
.design-workspace__resize-delta-label{
  font-size:0.78rem;
  letter-spacing:0.06em;
  text-transform:uppercase;
  color:#94a3b8;
}
.design-workspace__resize-delta-value{
  color:#f8fafc;
}
.design-workspace__resize-note{
  margin:0;
  color:#cbd5e1;
  line-height:1.45;
}
.design-workspace__resize-note--danger{
  color:#fecaca;
}
.design-workspace__resize-actions{
  display:flex;
  flex-wrap:wrap;
  gap:10px;
}
.design-workspace__resize-empty{
  margin:0;
  color:#94a3b8;
}

@media (max-width: 1080px){
  .design-workspace__body{
    grid-template-columns:1fr;
  }
  .design-workspace__resize-grid{
    grid-template-columns:1fr;
  }
  .design-workspace__resize-comparison{
    grid-template-columns:1fr;
  }
  .design-workspace__resize-arrow{
    display:none;
  }
}


/* Design workspace compact accordion refinement */
.design-workspace-panel{
  padding:12px 14px;
}
.design-workspace{
  gap:0;
}
.design-workspace__accordion{
  border:1px solid rgba(71,85,105,0.34);
  border-radius:16px;
  background:rgba(9,13,20,0.5);
  overflow:hidden;
}
.design-workspace__accordion[open]{
  background:rgba(9,13,20,0.62);
}
.design-workspace__accordion-summary{
  list-style:none;
  cursor:pointer;
  padding:12px 14px;
  display:flex;
  flex-direction:column;
  gap:10px;
}
.design-workspace__accordion-summary::-webkit-details-marker{
  display:none;
}
.design-workspace__accordion-summary::marker{
  content:"";
}
.design-workspace__accordion-heading{
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:12px;
}
.design-workspace__accordion-title-group{
  display:flex;
  flex-direction:column;
  gap:4px;
  min-width:0;
}
.design-workspace__accordion-title-group h2{
  margin:0;
  font-size:1.1rem;
}
.design-workspace__accordion-title-group p{
  margin:0;
  color:#9fb0c8;
  font-size:0.88rem;
}
.design-workspace__accordion-state{
  display:inline-flex;
  align-items:center;
  gap:8px;
  padding:6px 10px;
  border-radius:999px;
  background:rgba(17,24,39,0.9);
  border:1px solid rgba(71,85,105,0.34);
  color:#cbd5e1;
  font-size:0.78rem;
  white-space:nowrap;
}
.design-workspace__accordion-state::before{
  content:'+';
  font-weight:700;
  font-size:0.95rem;
  line-height:1;
}
.design-workspace__accordion[open] .design-workspace__accordion-state::before{
  content:'−';
}

.design-workspace__compact-summary{
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:12px;
  padding:10px 12px;
  border-radius:14px;
  background:rgba(8,15,27,0.72);
  border:1px solid rgba(71,85,105,0.24);
}
.design-workspace__compact-summary-copy{
  display:flex;
  flex-direction:column;
  gap:4px;
  min-width:0;
}
.design-workspace__compact-summary-copy strong{
  font-size:0.92rem;
  color:#f8fafc;
}
.design-workspace__compact-summary-copy span{
  color:#a8b8d1;
  font-size:0.82rem;
  line-height:1.45;
}
.design-workspace__summary-chips{
  display:flex;
  flex-wrap:wrap;
  justify-content:flex-end;
  gap:6px;
}
.design-workspace__summary-chip{
  display:inline-flex;
  align-items:center;
  min-height:28px;
  padding:0 10px;
  border-radius:999px;
  background:rgba(15,23,42,0.9);
  border:1px solid rgba(71,85,105,0.24);
  color:#dbe7f6;
  font-size:0.76rem;
  white-space:nowrap;
}
.design-workspace__compact-summary--good{ box-shadow: inset 0 0 0 1px rgba(34,197,94,0.16); }
.design-workspace__compact-summary--warn{ box-shadow: inset 0 0 0 1px rgba(245,158,11,0.18); }
.design-workspace__compact-summary--danger{ box-shadow: inset 0 0 0 1px rgba(248,113,113,0.18); }
.design-workspace__compact-summary--info{ box-shadow: inset 0 0 0 1px rgba(96,165,250,0.18); }

.design-workspace__compact-badges{
  display:flex;
  flex-wrap:wrap;
  gap:8px;
}
.design-workspace__compact-badge{
  display:inline-flex;
  align-items:center;
  gap:8px;
  min-width:0;
  padding:7px 10px;
  border-radius:999px;
  background:rgba(17,24,39,0.86);
  border:1px solid rgba(71,85,105,0.28);
}
.design-workspace__compact-badge-label{
  color:#8fa1bb;
  font-size:0.74rem;
  text-transform:uppercase;
  letter-spacing:0.06em;
}
.design-workspace__compact-badge-value{
  font-size:0.82rem;
  color:#f8fafc;
}
.design-workspace__compact-badge--good{ box-shadow: inset 0 0 0 1px rgba(34,197,94,0.18); }
.design-workspace__compact-badge--warn{ box-shadow: inset 0 0 0 1px rgba(245,158,11,0.2); }
.design-workspace__compact-badge--danger{ box-shadow: inset 0 0 0 1px rgba(248,113,113,0.2); }
.design-workspace__compact-badge--info{ box-shadow: inset 0 0 0 1px rgba(96,165,250,0.2); }
.design-workspace__accordion-body{
  display:flex;
  flex-direction:column;
  gap:16px;
  padding:0 14px 14px;
  border-top:1px solid rgba(71,85,105,0.22);
}
.design-workspace__summary{
  padding-top:14px;
}
.design-workspace__body{
  gap:14px;
}
.design-workspace__surface{
  padding:14px;
}
.design-workspace__badge-grid{
  grid-template-columns:repeat(auto-fit, minmax(150px, 1fr));
}
@media (max-width: 1120px){
  .design-workspace__accordion-heading{
    flex-direction:column;
    align-items:flex-start;
  }
}
@media (max-width: 820px){
  .design-workspace__accordion-summary{
    padding:11px 12px;
  }
  .design-workspace__accordion-body{
    padding:0 12px 12px;
  }
  
.design-workspace__compact-summary{
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:12px;
  padding:10px 12px;
  border-radius:14px;
  background:rgba(8,15,27,0.72);
  border:1px solid rgba(71,85,105,0.24);
}
.design-workspace__compact-summary-copy{
  display:flex;
  flex-direction:column;
  gap:4px;
  min-width:0;
}
.design-workspace__compact-summary-copy strong{
  font-size:0.92rem;
  color:#f8fafc;
}
.design-workspace__compact-summary-copy span{
  color:#a8b8d1;
  font-size:0.82rem;
  line-height:1.45;
}
.design-workspace__summary-chips{
  display:flex;
  flex-wrap:wrap;
  justify-content:flex-end;
  gap:6px;
}
.design-workspace__summary-chip{
  display:inline-flex;
  align-items:center;
  min-height:28px;
  padding:0 10px;
  border-radius:999px;
  background:rgba(15,23,42,0.9);
  border:1px solid rgba(71,85,105,0.24);
  color:#dbe7f6;
  font-size:0.76rem;
  white-space:nowrap;
}
.design-workspace__compact-summary--good{ box-shadow: inset 0 0 0 1px rgba(34,197,94,0.16); }
.design-workspace__compact-summary--warn{ box-shadow: inset 0 0 0 1px rgba(245,158,11,0.18); }
.design-workspace__compact-summary--danger{ box-shadow: inset 0 0 0 1px rgba(248,113,113,0.18); }
.design-workspace__compact-summary--info{ box-shadow: inset 0 0 0 1px rgba(96,165,250,0.18); }

.design-workspace__compact-badges{
    gap:6px;
  }
  .design-workspace__compact-badge{
    width:100%;
    justify-content:space-between;
  }
}
