*{box-sizing:border-box;margin:0}
body{background:#0d1117;color:#e6edf3;font-family:system-ui,-apple-system,sans-serif;line-height:1.45;min-height:100vh;display:flex;flex-direction:column}
a{color:#e6edf3;text-decoration:none}a:hover{text-decoration:underline}
header.top{display:flex;align-items:center;justify-content:space-between;padding:12px 20px;border-bottom:1px solid #21262d;gap:12px;flex-wrap:wrap}
header.top .logo{font-weight:700;font-size:18px;letter-spacing:.5px}header.top .logo span{color:#8b949e}
header.top nav a{margin-left:16px;font-size:14px}header.top nav a[aria-current]{color:#e5534b}
.bar{display:flex;gap:10px;align-items:center;padding:10px 20px;border-bottom:1px solid #21262d;flex-wrap:wrap;background:#0f141b}
.bar form{display:flex;gap:8px;flex:1 1 360px}
input[type=text],input[type=password],input[type=search]{background:#0d1117;border:1px solid #30363d;color:#e6edf3;border-radius:8px;padding:9px 12px;font-size:14px;min-width:0}
input:focus-visible,button:focus-visible,.node:focus-visible{outline:2px solid #e5534b;outline-offset:2px}
#seed{flex:1}
.btn{background:#21262d;border:1px solid #30363d;color:#fff;font-size:13px;font-weight:600;padding:8px 14px;border-radius:8px;cursor:pointer;white-space:nowrap}
.btn:hover{border-color:#8b949e}.btn.primary{background:#8b1a1a;border-color:#b62324}.btn.primary:hover{background:#a40e26}
.btn.ghost{background:transparent}.btn.danger{color:#ff7b72}
.key{display:flex;gap:8px;align-items:center;flex-wrap:wrap}.key input[type=password]{width:210px}
.key label,.bar label.chk{font-size:12px;color:#8b949e;display:flex;gap:5px;align-items:center}
#keyhint{font-size:12px;color:#8b949e}
.wrap{flex:1;display:grid;grid-template-columns:240px 1fr 340px;min-height:560px}
aside{border-right:1px solid #21262d;padding:14px;overflow:auto;max-height:calc(100vh - 140px)}
aside.right{border-right:0;border-left:1px solid #21262d}
aside h2{font-size:12px;letter-spacing:.08em;text-transform:uppercase;color:#8b949e;margin:14px 0 8px}aside h2:first-child{margin-top:0}
aside h4{font-size:13px;margin:16px 0 8px;color:#8b949e}
.stage{position:relative;min-height:420px;background:radial-gradient(circle at 50% 40%,#131a24,#0d1117 70%)}
#graph{width:100%;height:100%;display:block;touch-action:none;cursor:grab;position:absolute;inset:0}
.edge{stroke:#30363d;stroke-width:1.2}.edge.hl{stroke:#e5534b;stroke-width:2}
.edge-label{fill:#e6edf3;font-size:10px;text-anchor:middle;paint-order:stroke;stroke:#0d1117;stroke-width:3px}
.node{cursor:pointer}.node circle{stroke:#0d1117;stroke-width:2}.node.sel circle{stroke:#fff;stroke-width:3}
.node-icon{font-size:10px;font-weight:700;fill:#0d1117;text-anchor:middle;pointer-events:none}
.node-label{font-size:11px;fill:#e6edf3;text-anchor:middle;paint-order:stroke;stroke:#0d1117;stroke-width:3px;pointer-events:none}
.tools{position:absolute;right:12px;top:12px;display:flex;gap:6px;z-index:2}.tools .btn{padding:6px 10px}
#counts{position:absolute;left:12px;bottom:10px;font-size:12px;color:#8b949e;z-index:2}
#empty{position:absolute;inset:0;display:flex;flex-direction:column;align-items:center;justify-content:center;text-align:center;padding:24px;color:#8b949e;pointer-events:none;z-index:1}
#empty h1{color:#e6edf3;font-size:24px;margin-bottom:8px}#empty ol{text-align:left;margin-top:12px;font-size:14px}
#status{padding:8px 20px;font-size:13px;border-bottom:1px solid #21262d;min-height:35px;color:#8b949e}
#status[data-kind=ok]{color:#57ab5a}#status[data-kind=warn]{color:#c69026}#status[data-kind=err]{color:#ff7b72}
body.is-busy #status::before{content:"";display:inline-block;width:10px;height:10px;border:2px solid #8b949e;border-top-color:transparent;border-radius:50%;margin-right:8px;animation:spin .8s linear infinite;vertical-align:-1px}
@keyframes spin{to{transform:rotate(360deg)}}
ul.list{list-style:none;padding:0;display:flex;flex-direction:column;gap:6px}
ul.list li{background:#161b22;border:1px solid #21262d;border-radius:8px;padding:8px 28px 8px 10px;position:relative;font-size:13px}
ul.list li.cur{border-color:#8b1a1a}ul.list li small{display:block;color:#8b949e;font-size:11px}
ul.list li .x{position:absolute;right:6px;top:6px;background:none;border:0;color:#8b949e;font-size:16px;cursor:pointer}
.linkish{background:none;border:0;color:#e6edf3;cursor:pointer;text-align:left;padding:0;font:inherit}
.linkish:hover{text-decoration:underline}
li.muted,.muted{color:#8b949e;font-size:13px}
#findings li[data-sev] b{text-transform:uppercase;font-size:10px;letter-spacing:.05em;padding:1px 5px;border-radius:4px;background:#21262d}
#findings li[data-sev=critical] b,#findings li[data-sev=high] b{background:#8b1a1a;color:#fff}
#findings li[data-sev=medium] b{background:#5a3e00;color:#f5d67b}
.detail-head{display:flex;flex-direction:column;gap:6px}.detail-head h3{font-size:16px;word-break:break-all}
.chip{align-self:flex-start;font-size:11px;padding:2px 8px;border-radius:999px;background:#21262d;color:#e6edf3}
table.props{width:100%;border-collapse:collapse;font-size:12px;margin-top:10px}
table.props th{text-align:left;color:#8b949e;font-weight:600;padding:5px 8px 5px 0;vertical-align:top;white-space:nowrap;text-transform:capitalize}
table.props td{padding:5px 0;white-space:pre-wrap;word-break:break-word;border-bottom:1px solid #21262d}
.xforms{display:flex;flex-direction:column;gap:6px}
.xform{display:flex;justify-content:space-between;gap:8px;align-items:center;background:#161b22;border:1px solid #30363d;border-radius:8px;color:#e6edf3;padding:8px 10px;font-size:13px;cursor:pointer;text-align:left}
.xform:hover{border-color:#e5534b}.xform small{color:#8b949e;font-size:11px;white-space:nowrap}.xform.paid small{color:#c69026}
.row{display:flex;gap:6px;flex-wrap:wrap;margin-top:14px}
.exports{display:grid;grid-template-columns:1fr 1fr;gap:6px}
.file{display:block;text-align:center}.file input{display:none}
#findcount{background:#8b1a1a;color:#fff;border-radius:999px;padding:0 6px;font-size:10px;margin-left:4px}#findcount:empty{display:none}
footer{border-top:1px solid #21262d;padding:12px 20px;text-align:center;font-size:12px;color:#8b949e}
.sr{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0)}
@media(max-width:1000px){.wrap{grid-template-columns:1fr}aside{max-height:none;border-right:0;border-bottom:1px solid #21262d}aside.right{border-left:0}.stage{height:62vh;order:-1}.key input[type=password]{width:160px}}
.file{margin-top:6px}.note{margin-top:10px}
#empty[hidden]{display:none}
#invname{width:100%}
