/* massing-diagram-maker 1.0.0 */
/* illustrarch diagram kit styles. mdm is replaced with the plugin prefix at build time.
   Same visual language as the bubble, zoning and adjacency tools. */
.mdm-root{
  --mdm-ink:#1f2933; --mdm-mut:#5f6b7a; --mdm-line:#dcdfe3; --mdm-bg:#f6f7f9;
  --mdm-panel:#fff; --mdm-blue:#0073aa; --mdm-blue-d:#005a87; --mdm-green:#007f1e; --mdm-red:#c0392b;
  --mdm-h:620px;
  max-width:100%; margin:20px 0; border:1px solid var(--mdm-line); border-radius:8px; overflow:hidden;
  background:var(--mdm-bg); color:var(--mdm-ink); font-size:14px; line-height:1.4;
  font-family:-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,Helvetica,Arial,sans-serif;
}
.mdm-root *,.mdm-root *::before,.mdm-root *::after{box-sizing:border-box}
.mdm-root.mdm-dark{--mdm-ink:#e6eaf0;--mdm-mut:#9aa6b5;--mdm-line:#39424e;--mdm-bg:#1b2128;--mdm-panel:#232a33}

.mdm-head{display:flex;flex-wrap:wrap;gap:8px;padding:10px 12px;background:var(--mdm-panel);border-bottom:1px solid var(--mdm-line)}
.mdm-head input{flex:1 1 220px;min-width:0}
.mdm-bar{display:flex;flex-wrap:wrap;gap:6px;align-items:center;padding:8px 12px;background:var(--mdm-panel);border-bottom:1px solid var(--mdm-line)}
.mdm-grp{display:flex;flex-wrap:wrap;gap:4px;align-items:center;padding-right:8px;border-right:1px solid var(--mdm-line);min-width:0;max-width:100%}
.mdm-grp:last-child{border-right:0;padding-right:0}
.mdm-lab,.mdm-lab2{font-size:12px;color:var(--mdm-mut);white-space:nowrap;margin-right:2px}
.mdm-zl{font-size:12px;color:var(--mdm-mut);min-width:40px;text-align:center}

.mdm-btn{display:inline-flex;align-items:center;justify-content:center;gap:5px;padding:6px 10px;background:var(--mdm-blue);color:#fff;
  border:1px solid transparent;border-radius:4px;cursor:pointer;font-size:12px;line-height:1.2;white-space:nowrap}
.mdm-btn:hover{background:var(--mdm-blue-d)}
.mdm-btn:focus-visible,.mdm-root input:focus-visible,.mdm-root select:focus-visible{outline:3px solid #ffb900;outline-offset:1px}
.mdm-scroll:focus-visible{outline:2px solid #ffb900;outline-offset:-2px}
.mdm-btn.mdm-ghost,.mdm-btn.mdm-tool{background:transparent;color:var(--mdm-ink);border-color:var(--mdm-line)}
.mdm-btn.mdm-ghost:hover,.mdm-btn.mdm-tool:hover{background:var(--mdm-line)}
.mdm-btn.mdm-tool[aria-pressed="true"]{background:var(--mdm-blue);color:#fff;border-color:var(--mdm-blue)}
.mdm-btn.mdm-add{background:var(--mdm-green)}
.mdm-btn.mdm-add:hover{background:#006a18}
.mdm-btn.mdm-danger{background:var(--mdm-red)}
.mdm-btn.mdm-danger:hover{background:#a5322a}
.mdm-btn[disabled]{opacity:.45;cursor:not-allowed}
.mdm-file{position:absolute;width:1px;height:1px;opacity:0;pointer-events:none}

.mdm-tabs{display:flex;flex-wrap:wrap;gap:4px;align-items:center;padding:6px 12px;background:var(--mdm-bg);border-bottom:1px solid var(--mdm-line)}
.mdm-tablist{display:flex;flex-wrap:wrap;gap:4px;align-items:center}
.mdm-tab{padding:5px 12px;border:1px solid var(--mdm-line);border-radius:14px;background:var(--mdm-panel);color:var(--mdm-ink);cursor:pointer;font-size:12px;line-height:1.2}
.mdm-tab[aria-selected="true"]{background:var(--mdm-ink);color:var(--mdm-panel);border-color:var(--mdm-ink)}
.mdm-tabtools{display:inline-flex;flex-wrap:wrap;gap:4px;align-items:center;margin-left:auto}
.mdm-tabname{width:140px}

.mdm-main{display:flex;align-items:stretch;min-height:var(--mdm-h)}
.mdm-side{flex:0 0 290px;max-width:290px;display:flex;flex-direction:column;background:var(--mdm-panel);border-right:1px solid var(--mdm-line);
  max-height:calc(var(--mdm-h) + 140px);overflow:auto}
.mdm-sec{margin:0;padding:9px 12px;font-size:11px;font-weight:700;letter-spacing:.06em;text-transform:uppercase;color:var(--mdm-mut);
  border-bottom:1px solid var(--mdm-line);border-top:1px solid var(--mdm-line);background:var(--mdm-bg)}
.mdm-sec:first-child{border-top:0}
.mdm-side > *{flex:0 0 auto}
.mdm-list{list-style:none;margin:0;padding:4px;max-height:220px;overflow:auto}
.mdm-li{display:grid;grid-template-columns:minmax(0,1fr) auto auto;gap:3px;align-items:center;padding:2px;border-radius:4px}
.mdm-li.mdm-on{background:var(--mdm-bg);box-shadow:inset 0 0 0 1px var(--mdm-blue)}
.mdm-pick{display:flex;align-items:center;gap:7px;min-width:0;padding:4px 6px;background:none;border:0;color:var(--mdm-ink);cursor:pointer;text-align:left;font-size:13px}
.mdm-nm{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;min-width:0}
.mdm-sw{flex:0 0 12px;width:12px;height:12px;border-radius:2px;border:1px solid rgba(0,0,0,.25)}
.mdm-mini{padding:2px 6px;font-size:11px;background:none;border:1px solid var(--mdm-line);border-radius:3px;color:var(--mdm-mut);cursor:pointer}
.mdm-mini[aria-pressed="true"]{color:var(--mdm-ink);background:var(--mdm-bg)}
.mdm-empty{padding:10px;color:var(--mdm-mut);font-size:13px}
.mdm-props,.mdm-extra{padding:8px 12px}
.mdm-extra:empty{display:none}
.mdm-kind{margin:0 0 6px;font-size:12px;font-weight:700;color:var(--mdm-mut)}
.mdm-muted{margin:0;color:var(--mdm-mut);font-size:13px}
.mdm-readout{margin:6px 0 0;font-size:12px;color:var(--mdm-mut)}
.mdm-row{display:grid;grid-template-columns:96px minmax(0,1fr);gap:4px 8px;align-items:center;margin:0 0 6px}
.mdm-row label{font-size:12px;color:var(--mdm-mut);margin:0}
.mdm-row.mdm-chk{grid-template-columns:auto minmax(0,1fr)}
.mdm-row.mdm-chk input{order:-1}
.mdm-row.mdm-under{grid-template-columns:auto auto auto;justify-content:start}
.mdm-inu{display:flex;align-items:center;gap:4px;min-width:0}
.mdm-unit{font-size:11px;color:var(--mdm-mut);white-space:nowrap}
.mdm-fnote{grid-column:1 / -1;color:var(--mdm-mut);font-size:11px}

.mdm-stage{flex:1 1 auto;min-width:0;display:flex;flex-direction:column;background:var(--mdm-bg)}
.mdm-scroll{flex:1 1 auto;overflow:auto;max-height:calc(var(--mdm-h) + 140px);padding:10px;min-height:260px}
.mdm-svg{display:block;margin:0 auto;max-width:none;background:transparent;user-select:none;-webkit-user-select:none}
.mdm-svg.mdm-drawmode{cursor:crosshair;touch-action:none}
.mdm-it{cursor:move}
.mdm-it,.mdm-hd{touch-action:none}
.mdm-hd{cursor:pointer}
.mdm-hid{opacity:.25}
.mdm-locked{cursor:default}
.mdm-second{border-top:1px solid var(--mdm-line);background:var(--mdm-panel)}
.mdm-foot{display:flex;flex-wrap:wrap;gap:6px 12px;align-items:center;justify-content:space-between;padding:6px 12px;min-height:34px;
  background:var(--mdm-panel);border-top:1px solid var(--mdm-line);font-size:12px;color:var(--mdm-mut)}
.mdm-note{display:flex;flex-wrap:wrap;gap:6px;align-items:center;color:var(--mdm-ink)}
.mdm-note:empty{display:none}
.mdm-linkbox{width:min(420px,70vw)}

@media (max-width:860px){
  .mdm-main{flex-direction:column}
  .mdm-side{flex:none;max-width:none;max-height:none;border-right:0;border-top:1px solid var(--mdm-line);order:2}
  .mdm-stage{order:1}
  .mdm-scroll{max-height:none;padding:6px}
  .mdm-tabtools{margin-left:0}
  .mdm-grp{border-right:0;padding-right:0}
}

/* ==================================================================
   THEME RESET (bopea / JNews on illustrarch): the theme gives buttons a
   fixed height, flex and capitalised text, inputs 13 px padding and 15 px
   text, selects height 40 px and appearance none, labels a bottom margin,
   lists padding and markers. Measured on the zoning and adjacency tools;
   scoped to the tool root with !important so the tool keeps its sizes.
   ================================================================== */
.mdm-root button,.mdm-root input,.mdm-root select{
  text-transform:none!important;letter-spacing:normal!important;font-family:inherit!important;box-shadow:none!important;
  height:auto!important;min-height:0!important;margin:0!important;line-height:1.25!important;transition:none!important;
  max-width:100%;
}
.mdm-root .mdm-btn{color:#fff!important;font-size:12px!important;padding:6px 10px!important;border-radius:4px!important;font-weight:500!important;width:auto!important}
.mdm-root .mdm-btn.mdm-ghost,.mdm-root .mdm-btn.mdm-tool{color:var(--mdm-ink)!important;background:transparent!important;border:1px solid var(--mdm-line)!important}
.mdm-root .mdm-btn.mdm-ghost:hover,.mdm-root .mdm-btn.mdm-tool:hover{background:var(--mdm-line)!important}
.mdm-root .mdm-btn.mdm-tool[aria-pressed="true"]{color:#fff!important;background:var(--mdm-blue)!important;border-color:var(--mdm-blue)!important}
.mdm-root .mdm-btn:not(.mdm-ghost):not(.mdm-tool):not(.mdm-add):not(.mdm-danger){background:var(--mdm-blue)!important}
.mdm-root .mdm-btn.mdm-add{background:var(--mdm-green)!important}
.mdm-root .mdm-btn.mdm-danger{background:var(--mdm-red)!important}
.mdm-root .mdm-tab{color:var(--mdm-ink)!important;background:var(--mdm-panel)!important;border:1px solid var(--mdm-line)!important;
  padding:5px 12px!important;font-size:12px!important;border-radius:14px!important}
.mdm-root .mdm-tab[aria-selected="true"]{color:var(--mdm-panel)!important;background:var(--mdm-ink)!important;border-color:var(--mdm-ink)!important}
.mdm-root .mdm-pick{background:none!important;color:var(--mdm-ink)!important;padding:4px 6px!important;font-size:13px!important;border:0!important;width:auto!important}
.mdm-root .mdm-mini{background:none!important;color:var(--mdm-mut)!important;padding:2px 6px!important;font-size:11px!important;border:1px solid var(--mdm-line)!important;width:auto!important}
.mdm-root .mdm-mini[aria-pressed="true"]{color:var(--mdm-ink)!important;background:var(--mdm-bg)!important}
.mdm-root input[type="text"],.mdm-root select{
  padding:6px 8px!important;font-size:13px!important;border:1px solid var(--mdm-line)!important;border-radius:4px!important;
  color:var(--mdm-ink)!important;background:var(--mdm-panel)!important;width:100%!important;min-width:0!important
}
.mdm-root .mdm-head input[type="text"]{font-size:15px!important;padding:8px 10px!important;width:auto!important;background:var(--mdm-bg)!important}
.mdm-root .mdm-head input.mdm-sub{font-size:13px!important}
.mdm-root .mdm-bar select{width:auto!important;max-width:220px}
.mdm-root input.mdm-tabname{width:140px!important}
.mdm-root select{-webkit-appearance:menulist!important;-moz-appearance:menulist!important;appearance:auto!important}
.mdm-root input[type="checkbox"]{width:20px!important;height:20px!important;padding:0!important;margin:2px!important;accent-color:var(--mdm-blue)}
.mdm-root .mdm-row.mdm-chk{min-height:26px;margin-bottom:8px}
.mdm-root p.mdm-muted,.mdm-root p.mdm-kind,.mdm-root p.mdm-readout{color:var(--mdm-mut)!important;font-size:13px!important;line-height:1.4!important;margin:0 0 6px!important}
.mdm-root .mdm-props p,.mdm-root .mdm-extra p{color:var(--mdm-ink)}
.mdm-root input[type="range"]{width:100%!important;padding:0!important;border:0!important;background:none!important}
.mdm-root input[type="color"]{width:44px!important;height:28px!important;padding:2px!important;border:1px solid var(--mdm-line)!important;border-radius:4px!important;background:var(--mdm-panel)!important}
.mdm-root label{margin:0!important;font-weight:400!important;display:inline!important}
.mdm-root ul.mdm-list{padding:4px!important;margin:0!important;list-style:none!important}
.mdm-root li.mdm-li,.mdm-root li.mdm-empty{margin:0!important;border:0!important;list-style:none!important}
.mdm-root li.mdm-li::before,.mdm-root li.mdm-li::marker,.mdm-root li.mdm-empty::before{content:none!important;display:none!important}
.mdm-root .mdm-sec{font-family:inherit!important;line-height:1.3!important}
.mdm-root p{margin-top:0;text-align:left!important;hyphens:manual}
.mdm-root svg text{font-family:Helvetica,Arial,sans-serif}
.mdm-root table{margin:0!important;border-collapse:collapse!important}
.mdm-root td,.mdm-root th{border:0!important;border-bottom:1px solid var(--mdm-line)!important;padding:4px 6px!important;font-size:12px!important;background:none!important;color:var(--mdm-ink)!important}
/* phones: typing in a field under 16 px makes iOS zoom the page */
@media (max-width:860px){
  .mdm-root input[type="text"],.mdm-root select,
  .mdm-root .mdm-head input[type="text"],.mdm-root .mdm-head input.mdm-sub,
  .mdm-root .mdm-bar select,.mdm-root .mdm-row input[type="text"]{font-size:16px!important}
}

/* Massing Diagram Maker extras: plan and axonometric side by side */
.mdm-stage{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);align-items:start}
.mdm-second{border-top:0;border-left:1px solid var(--mdm-line);min-width:0;display:flex;flex-direction:column}
.mdm-axobar{padding:6px 10px;display:flex;flex-direction:column;gap:6px;border-bottom:1px solid var(--mdm-line)}
.mdm-axorow{display:flex;flex-wrap:wrap;gap:6px 10px;align-items:center}
.mdm-chk{display:inline-flex;align-items:center;gap:4px;font-size:12px}
.mdm-root .mdm-chk label,.mdm-root .mdm-lab{font-size:12px!important;color:var(--mdm-ink)!important;line-height:1.2!important}
.mdm-axowrap{padding:8px}
.mdm-axo{display:block;width:100%;height:auto;max-height:calc(var(--mdm-h) + 40px)}
.mdm-axo-it{cursor:pointer}
.mdm-axo-on path{stroke:#0073aa!important;stroke-width:0.6!important}
.mdm-sunnote{padding:4px 10px 8px;font-size:11px;color:var(--mdm-mut)}
.mdm-sunnote:empty{display:none}
.mdm-root .mdm-axobar input.mdm-n{width:64px!important}
.mdm-root .mdm-axobar select{width:auto!important}
.mdm-root .mdm-axobar input.mdm-hour{width:140px!important;flex:1 1 120px}
.mdm-root table.mdm-fig{width:100%;margin:0 0 6px!important}
.mdm-root .mdm-fig th{text-align:left!important;font-weight:400!important;color:var(--mdm-mut)!important}
.mdm-root .mdm-fig td{text-align:right!important;font-variant-numeric:tabular-nums}
.mdm-root .mdm-cmp thead th{font-weight:700!important;color:var(--mdm-ink)!important;text-align:right!important}
.mdm-figwrap{overflow-x:auto;max-width:100%}
.mdm-use th{display:flex;align-items:center;gap:6px}
.mdm-root p.mdm-fnote2{font-size:11px!important;color:var(--mdm-mut)!important;margin:0 0 6px!important;line-height:1.35!important}
.mdm-stack{display:flex;flex-wrap:wrap;gap:6px;align-items:center;margin:0 0 8px}
.mdm-muted2{font-size:11px;color:var(--mdm-mut)}
.mdm-next{margin-left:auto;white-space:normal}
.mdm-next a{color:var(--mdm-blue)!important;text-decoration:underline}
.mdm-dark .mdm-next a{color:#7cc4ff!important}
.mdm-dark .mdm-axowrap{background:#f3f1ec}
@media (max-width:1100px){
  .mdm-stage{grid-template-columns:minmax(0,1fr)}
  .mdm-second{border-left:0;border-top:1px solid var(--mdm-line)}
}
.mdm-cmpwrap{background:var(--mdm-panel);border-top:1px solid var(--mdm-line);padding:0 0 8px}
.mdm-cmpwrap[hidden]{display:none}
.mdm-cmpwrap .mdm-figwrap{padding:0 12px}
.mdm-root .mdm-cmp td,.mdm-root .mdm-cmp thead th{white-space:nowrap}
