:root{color-scheme:light;--ink:#242520;--muted:#63645b;--paper:#fff;--wash:#f8f7f4;--line:#e7e5df;--accent:#a94736;font:15px/1.45 system-ui,sans-serif;background:var(--wash);color:var(--ink)}
*{box-sizing:border-box}body{margin:0}button,input{font:inherit}button{border:0;color:inherit;background:none;cursor:pointer;min-height:44px;display:inline-flex;align-items:center;justify-content:center;gap:7px;border-radius:8px;padding:0 12px;font-size:13px;font-weight:650}button:hover:not(:disabled){background:#efeee9}button:disabled{opacity:.36;cursor:default}button:focus-visible,input:focus-visible{outline:2px solid var(--accent);outline-offset:2px}[hidden]{display:none!important}svg{width:19px;height:19px;fill:none;stroke:currentColor;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round;flex:none}.symbols{position:absolute;width:0;height:0;overflow:hidden}
.masthead{background:#fff;border-bottom:1px solid var(--line);padding-top:env(safe-area-inset-top)}.mast-inner{max-width:1012px;margin:auto;min-height:64px;padding:0 max(16px,env(safe-area-inset-right)) 0 max(16px,env(safe-area-inset-left));display:flex;align-items:center;justify-content:space-between}.brand{display:flex;align-items:center;gap:3px;font-weight:780;font-size:19px;letter-spacing:-.06em}.brand-mark{display:grid;place-items:center;width:34px;height:34px;margin-right:5px;background:#f6e7e0;color:var(--accent);border-radius:10px}.brand-mark svg{width:24px;height:24px}.brand-ink{font-weight:550;color:#66645b}.export{background:#292b25;color:#fff;padding:0 13px}.export:hover:not(:disabled){background:#424439}.export svg{width:17px;height:17px}
main{max-width:1012px;margin:auto;padding:22px max(16px,env(safe-area-inset-right)) max(8px,env(safe-area-inset-bottom)) max(16px,env(safe-area-inset-left))}.intro{margin-bottom:16px}.eyebrow,.sheet-bar>span,.sheet-foot>span:last-child{font:650 10px/1.3 system-ui,sans-serif;letter-spacing:.15em}.eyebrow{color:var(--accent)}h1{font:400 clamp(42px,9vw,66px)/.99 Georgia,serif;letter-spacing:-.064em;margin:5px 0 5px}h1 span{color:var(--accent)}.intro p{margin:0;color:var(--muted);font-size:14px}
.toolbox{background:#fff;border:1px solid var(--line);border-radius:12px;padding:4px 8px 2px}.tool-row,.settings,.group,.size,.colors,.swatches{display:flex;align-items:center}.tool-row{justify-content:space-between}.group button{min-width:44px;padding:0 9px}.group button[aria-pressed=true]{background:#f5e9e2;color:#863d30}.settings{border-top:1px solid #eeede8;justify-content:space-between;gap:4px;margin-top:4px;padding:0 1px}.size{gap:5px;flex:1;min-width:0}.size label,.field-label{font-weight:650;font-size:12px}.size output{font:600 11px/1 system-ui,sans-serif;white-space:nowrap;min-width:28px;text-align:center;color:var(--muted)}input[type=range]{cursor:pointer;accent-color:var(--accent);width:100%;min-width:22px;height:33px;margin:0}.colors{gap:3px}.swatches button{min-height:44px;width:clamp(22px,8vw,44px);padding:0}.swatch-dot{display:block;width:18px;height:18px;background:var(--swatch);border-radius:50%;outline-offset:2px}.swatches button[aria-pressed=true] .swatch-dot{outline:1.5px solid #373830}
.sheet-bar,.sheet-foot{display:flex;align-items:center;justify-content:space-between;color:var(--muted)}.sheet-bar{margin:3px 0 1px}.sheet-bar>span,.sheet-foot>span:first-child{display:flex;align-items:center;gap:6px}.sheet-bar i{width:6px;height:6px;background:#b85d4a;border-radius:50%}.sheet-bar button{color:#514f46;padding:0 3px 0 8px}.sheet-bar button[aria-pressed=true]{color:#863d30;background:#f5e9e2}.sheet-bar button svg,.sheet-foot svg{width:15px;height:15px}
.paper{position:relative;aspect-ratio:9/10;background:#fff;border-radius:8px;outline:1px solid #dfddd5;overflow:hidden;box-shadow:0 3px 12px #292b2509}.paper canvas,.paper img{position:absolute;inset:0;width:100%;height:100%;display:block}.paper canvas{touch-action:none;user-select:none;-webkit-user-select:none;cursor:crosshair}.paper img,.corner{pointer-events:none}.corner{position:absolute;width:10px;height:10px;border:0 solid #dedbd1}.tl{top:10px;left:10px;border-width:1px 0 0 1px}.tr{top:10px;right:10px;border-width:1px 1px 0 0}.bl{bottom:10px;left:10px;border-width:0 0 1px 1px}.br{bottom:10px;right:10px;border-width:0 1px 1px 0}.sheet-foot{min-height:30px;font-size:11px}.sheet-foot svg{color:#637458}
footer{display:flex;align-items:center;justify-content:space-between;gap:10px;color:var(--muted);font-size:11px}footer button{padding:0;text-decoration:underline;text-underline-offset:3px}footer button:hover:not(:disabled){background:none;color:var(--ink)}footer p{margin:0;text-align:right}
dialog{width:min(380px,calc(100% - 32px));border:1px solid var(--line);border-radius:14px;padding:20px;color:var(--ink);background:#fff}dialog::backdrop{background:#292b2560}dialog h2{font:400 29px/1.1 Georgia,serif;margin:0}dialog p{color:var(--muted)}dialog form,.dialog-actions{display:flex;justify-content:flex-end;gap:8px;flex-wrap:wrap}
@media(max-width:360px){#eraser span{display:none}.field-label{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%)}.size output{min-width:24px}}
@media(min-width:760px){main{padding-top:31px}.intro{margin-bottom:16px}.workspace{display:grid;grid-template-columns:268px minmax(0,540px);gap:25px;align-items:start}.toolbox{padding:6px 9px}.group button{padding:0 7px}#eraser span{display:none}.settings{display:grid;padding:6px 4px 0}.size{gap:10px}.colors{gap:8px}.swatches button{width:34px}.sheet-bar{margin:-9px 0 1px}.sheet-bar button{padding-inline:8px}}
