body.tool { background: var(--mist); }
.wrap.wide { width: min(1500px, 100% - 32px); }
.nav .staff { margin-left: 16px; color: var(--muted); font-size: 13px; position: relative; }
.nav .staff summary { cursor: pointer; font-weight: 500; font-size: 13px; }
.nav .staff > div { position: absolute; right: 0; top: 30px; background: #fff; padding: 14px; border-radius: 10px; width: 260px; display: grid; gap: 10px; z-index: 30; }
.nav .staff input { width: 100%; margin-top: 4px; }
.nav nav { margin-left: auto; }

.layout { width: min(1500px, 100% - 32px); margin: 20px auto 60px; display: grid; grid-template-columns: 380px minmax(0, 1fr); gap: 20px; align-items: start; }
.panel { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; position: sticky; top: 80px; max-height: calc(100vh - 100px); overflow: auto; }
fieldset { border: 0; border-top: 1px solid var(--line); margin: 0; padding: 14px 0 6px; min-width: 0; }
fieldset:first-of-type { border-top: 0; padding-top: 4px; }
legend { font-weight: 700; font-size: 14px; padding: 0 8px 0 0; float: left; width: 100%; margin-bottom: 8px; }
legend + * { clear: both; }
.muted { color: var(--muted); font-weight: 400; font-size: 12px; }
label { display: grid; gap: 4px; font-size: 12.5px; color: var(--muted); font-weight: 600; }
label small { font-weight: 400; }
input, select { font: inherit; font-size: 14px; color: var(--text); padding: 8px 9px; border: 1px solid #c8d1df; border-radius: 8px; background: #fff; width: 100%; min-width: 0; }
input:disabled { background: #eef1f6; color: #9aa6b8; }
input[type=checkbox], input[type=radio] { width: auto; accent-color: var(--cut); }
label.chk { display: flex; align-items: center; gap: 8px; align-self: end; padding-bottom: 8px; color: var(--text); font-size: 13.5px; font-weight: 600; }
.row3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; margin-bottom: 8px; align-items: end; }
.zoom { display: flex; align-items: center; gap: 8px; font-size: 12.5px; }
.zoom input { width: 90px; padding: 0; }
.hint { font-size: 12px; color: var(--muted); margin: 2px 0 10px; }
.seg { display: flex; flex-wrap: wrap; gap: 6px 16px; margin-bottom: 10px; }
.seg label { display: flex; align-items: center; gap: 6px; color: var(--text); font-size: 13.5px; }
.zrow { display: grid; grid-template-columns: 1fr 110px; gap: 10px; align-items: end; margin-bottom: 8px; }
.presets { display: grid; grid-template-columns: 1fr; gap: 6px; padding-bottom: 12px; }
.presets > * { min-width: 0; }
.btn.sm { padding: 8px 12px; font-size: 13px; }
.ghost-d { border-color: #c8d1df; color: var(--text); background: #fff; }
.ghost-d:hover { background: var(--mist); }

.stage { min-width: 0; display: grid; gap: 14px; }
.warn:empty { display: none; }
.warn { background: #fff7e6; border: 1px solid #f4d48a; border-radius: 10px; padding: 10px 14px; font-size: 13.5px; color: #6b4b00; }
.warn.err { background: #ffecef; border-color: #f2a3b0; color: #7a1020; }
.warn ul { margin: 0; padding-left: 18px; }
.toolbar { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.toolbar .spacer { flex: 1; }
.toolbar select { width: auto; padding: 7px 8px; font-size: 13px; }
.op { display: flex; align-items: center; gap: 8px; font-size: 12.5px; }
.op input { width: 110px; padding: 0; }
.artreport { border-radius: 10px; padding: 10px 14px; font-size: 13.5px; border: 1px solid var(--line); background: #fff; }
.artreport.bad { border-color: #f2a3b0; background: #ffecef; color: #7a1020; }
.artreport.ok { border-color: #a9ddb8; background: #edf9f0; color: #14532d; }
.artreport ul { margin: 6px 0 0; padding-left: 18px; }
.preview { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 10px; overflow: auto; min-height: 220px; }
.preview svg { display: block; width: 100%; height: auto; min-width: 640px; max-width: none; }
.request { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; }
.request h2 { font-size: 22px; margin-bottom: 4px; }
.request form { display: grid; gap: 8px; margin-top: 14px; }
.request .span2 { grid-column: span 2; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.reqmsg { font-size: 14px; margin-left: 12px; }
.reqmsg.ok { color: #14532d; } .reqmsg.bad { color: #7a1020; }
.staffdl { margin-top: 14px; padding-top: 12px; border-top: 1px dashed var(--line); display: flex; gap: 8px; align-items: center; }
#reqBtn { justify-self: start; }

@media (max-width: 980px) {
  .layout { grid-template-columns: 1fr; }
  .panel { position: static; max-height: none; }
  .row3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .request .span2 { grid-column: span 2; }
}
[hidden] { display: none !important; }
.rules { margin: 4px 0 0; padding-left: 18px; font-size: 12px; color: var(--muted, #5b6b7a); }
.rules li { margin: 2px 0; }
.stylepick select { font-weight: 600; }

.more{margin:8px 0}.more summary{cursor:pointer;color:#000099}.chk{display:flex;gap:8px;align-items:flex-start;font-size:14px;margin:8px 0}.chk input{width:auto;margin-top:3px}.thanks{padding:16px;border:1px solid #000099;border-radius:8px;background:#f2f3ff}

.panel, .request, .preview, .artreport { box-shadow: 0 1px 3px rgba(26,35,50,.06); }
input, select { border-color: #d0d7e2; border-radius: 0.5rem; }
input:focus, select:focus { border-color: #31358a; }
legend { font-family: var(--font-display); color: #31358a; }
.nav .staff > div { background: #fff; border: 1px solid var(--line); box-shadow: 0 8px 24px rgba(26,35,50,.12); }
.nav .staff summary { color: var(--muted); }
.more summary { color: #31358a; } .thanks { border-color: #31358a; background: #e8e9f5; }

.resetrow { display: flex; justify-content: flex-end; margin-bottom: 8px; }
.preview.stale svg { opacity: .35; filter: grayscale(1); transition: opacity .15s; }
.preview.stale::before { content: "Preview not updated - fix the issue above"; display: block; font-size: 13px; font-weight: 600; color: #7a1020; margin-bottom: 6px; }
label.need input, label.need select { border-color: #c42b47; box-shadow: 0 0 0 2px rgba(196,43,71,.18); }
.needtip { color: #c42b47; font-weight: 600; font-size: 12px; line-height: 1.3; }
.layout { grid-template-columns: 420px minmax(0, 1fr); }
.panel .row3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }

/* v0.19 */
.reqbtns { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; margin-top: 8px; }
.reqbtns .reqmsg { margin-left: 0; flex-basis: 100%; }
.presets { border-top: 1px solid #dfe5ee; padding: 14px 0 0; margin-top: 10px; }
