.md-categories { display:flex; gap:24px; border-bottom:1px solid var(--hair); margin-bottom:24px; }
.md-categories button { min-height:44px; border-bottom:2px solid transparent; color:var(--muted); font-size:14px; padding:0 3px; }
.md-categories [aria-selected=true] { border-color:var(--cobalt); color:var(--cobalt); }
.md-workbench { display:grid; grid-template-columns:210px minmax(0,1fr); gap:28px; align-items:start; }
.md-sidebar { min-width:0; }
.md-module-list { display:grid; gap:4px; margin-top:10px; }
.md-module-list button { display:flex; justify-content:space-between; align-items:center; gap:8px; min-height:48px; padding:10px 12px; border-radius:5px; text-align:left; color:var(--muted); font-size:13px; }
.md-module-list button[aria-pressed=true] { background:#e9edfa; color:var(--cobalt); }
.md-preview { min-width:0; border:1px solid var(--hair); border-radius:8px; overflow:hidden; background:white; }
.md-preview-bar { display:flex; align-items:center; justify-content:space-between; gap:8px; min-height:42px; padding:8px 16px; border-bottom:1px solid var(--hair); color:var(--muted); font-size:11px; }
.md-preview-bar button { min-height:28px; font-size:11px; text-decoration:underline; text-underline-offset:3px; }
.md-canvas { height:440px; overflow:auto; padding:20px; }
.md-panel { min-width:0; font-size:13px; }
.md-panel[hidden],.home-module-group[hidden] { display:none!important; }
.md-toolbar { display:flex; flex-wrap:wrap; gap:14px; justify-content:space-between; align-items:end; margin-bottom:16px; }
.md-field { display:grid; gap:6px; min-width:0; margin:0 0 14px; font-size:12px; color:var(--muted); }
.md-field input,.md-field textarea,.md-field select,.md-row select { width:100%; max-width:100%; padding:9px 10px; border:1px solid #d8d8de; border-radius:5px; background:white; color:var(--ink); font:inherit; line-height:1.5; }
.md-field textarea { resize:vertical; }
.md-field input[type=file] { padding:8px; font-size:12px; }
.md-toolbar .md-field { margin:0; flex:1; min-width:110px; }
.md-design-frame { display:block; width:100%; height:320px; border:1px solid var(--hair); border-radius:5px; }
.md-button { display:inline-flex; align-items:center; justify-content:center; min-height:38px; padding:8px 13px; border:1px solid #cbd5f1; border-radius:5px; color:var(--cobalt); font-size:12px; margin:0 6px 8px 0; }
.md-button:hover:not(:disabled) { background:#edf1ff; }
.md-button:disabled,.md-row button:disabled { opacity:.45; cursor:default; }
.md-hint { color:var(--muted); font-size:11px; line-height:1.6; margin:10px 0; }
.md-feedback { min-height:26px; margin:0; padding:0 20px 8px; color:var(--muted); font-size:11px; }
.md-checks { list-style:none; padding:0; margin:10px 0; display:grid; gap:12px; color:#2c6951; font-size:13px; }
.md-receipt { display:grid; gap:10px; margin-bottom:22px; }
.md-receipt strong { font-size:28px; font-weight:500; }
.md-status { color:var(--muted); font-size:12px; }
.md-rows { list-style:none; padding:0; margin:12px 0; }
.md-rows li,.md-row { display:flex; justify-content:space-between; align-items:center; gap:12px; padding:12px 0; border-bottom:1px solid var(--hair); font-size:12px; }
.md-rows li > span,.md-row > span { min-width:0; overflow-wrap:anywhere; }
.md-rows small,.md-row small { display:block; color:var(--muted); font-size:10px; margin-top:4px; }
.md-row button { flex:none; color:var(--cobalt); font-size:11px; min-height:32px; }
.md-row select { flex:none; width:112px; font-size:11px; }
.md-toggle { display:flex; align-items:center; gap:9px; min-height:42px; font-size:12px; }
.md-toggle input { width:16px; height:16px; accent-color:var(--cobalt); }
.md-job { white-space:pre-wrap; overflow-wrap:anywhere; min-height:42px; padding:14px; margin-top:10px; background:#f4f5f8; border-radius:5px; font-size:12px; }
.md-metrics { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:12px; margin:0 0 18px; }
.md-metrics span { display:block; font-size:11px; color:var(--muted); }
.md-metrics strong { display:block; font-size:22px; line-height:1.5; font-weight:500; }
.md-chart { width:100%; max-height:150px; fill:#7998ef; background:linear-gradient(to bottom,transparent 98%,#e8e9ef 98%); background-size:100% 33%; }
.md-inline-form { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:0 12px; align-items:end; }
.md-inline-form .md-button { justify-self:start; }
.md-panel h4 { margin:14px 0 8px; font-size:13px; font-weight:500; }
@media(max-width:680px){.md-workbench { grid-template-columns:1fr; gap:16px; }.md-module-list { grid-template-columns:repeat(2,minmax(0,1fr)); }.md-module-list button { font-size:12px; padding:8px; }.md-canvas { padding:14px; height:450px; }.md-preview-bar { padding-inline:12px; }.md-metrics { gap:8px; }.md-metrics strong { font-size:19px; }.md-inline-form { grid-template-columns:1fr; }.md-design-frame { height:300px; }}

.md-design-frame[aria-busy=true] { opacity:.4; pointer-events:none; }

.md-workbench{overflow-anchor:none}

.md-module-list button:disabled,.md-categories button:disabled{opacity:.5;cursor:progress}

/* Design demo: give the embedded site room, and signal that it continues below instead of looking clipped. */
.md-canvas { height:500px; }
#md-panel-design:not([hidden]) { display:flex; flex-direction:column; height:100%; }
#md-panel-design .md-toolbar { flex:none; }
.md-frame-wrap { position:relative; flex:1; min-height:0; }
.md-frame-wrap::after { content:''; position:absolute; left:1px; right:1px; bottom:1px; height:44px; border-radius:0 0 5px 5px; background:linear-gradient(rgba(255,255,255,0),#fff); pointer-events:none; }
.md-design-frame { height:100%; }
@media(max-width:680px){
 .md-canvas { height:560px; }
 #md-panel-design .md-toolbar { display:grid; grid-template-columns:1fr; gap:10px; }
 #md-panel-design .md-toolbar .quiet-link { justify-self:start; }
 .md-design-frame { height:100%; }
}
