
:root{color-scheme:light;--ink:#292633;--muted:#595368;--line:#d9d1e4;--bg:#f8f5fa;--accent:#533a70;--soft:#f0e9f4}
*{box-sizing:border-box}body{margin:0;background:var(--bg);color:var(--ink);font:15px/1.45 system-ui,sans-serif}
header,main,footer{width:min(76rem,100%);margin:auto;padding:.8rem 1.13rem}header,footer{display:flex;gap:1rem;flex-wrap:wrap;border-bottom:1px solid var(--line)}
footer{border:0;border-top:1px solid var(--line);margin-top:1rem}a{color:var(--accent)}
h1{font-size:clamp(2rem,5vw,3.25rem);letter-spacing:-.05em;line-height:1.08;margin:.25rem 0 .5rem}
h2{font-size:1.15rem;margin:.05rem 0 .5rem}.help,main>p{color:var(--muted)}
.panel{background:white;border:1px solid var(--line);border-radius:10px;padding:.85rem;min-width:0;margin:.65rem 0}
label,summary{font-weight:650}textarea,select,button{font:inherit;color:var(--ink);background:white;border:1px solid var(--line);border-radius:5px;padding:.36rem .46rem;max-width:100%}
textarea{display:block;width:100%;resize:vertical;background:#fcfafc}
#source,#output{font:13px/1.45 ui-monospace,monospace;min-height:6.5rem;margin:.35rem 0}
button,summary{cursor:pointer}button{font-weight:650}button:disabled{cursor:default;opacity:.54}
.primary{background:var(--accent);border-color:var(--accent);color:#fff}
.actions{display:flex;align-items:center;flex-wrap:wrap;gap:.48rem;margin:.55rem 0}
#status{color:#94364a;font-weight:650;margin:.35rem 0}#dimensions{font-weight:680;margin:.45rem 0}
#grid-scroll{max-height:27rem;overflow:auto}
table{width:100%;border-collapse:collapse}
th,td{padding:.28rem;border:1px solid var(--line);vertical-align:top;min-width:7.5rem}
tr>th:first-child{min-width:3.5rem}
thead th{background:var(--soft);text-align:left}
thead th span{display:block;font-size:.82rem}
thead th select{font-size:.78rem;margin:.18rem 0 .30rem;width:100%}
td textarea,th textarea{font-size:.85rem;height:2rem;line-height:1.15;min-height:2rem}
.widget{padding:.6rem}.widget main{padding:.15rem}
:focus-visible{outline:2px solid var(--accent);outline-offset:2px}
